SolidJSS
SolidJS2y ago
ap32

How to add babel plugin into new configuration?

Some time ago i created small code transformer using babel https://github.com/ap32/sample-site-finsweet-cft-12/blob/main/macro/join/index.ts#L21
I made it for simpler multiline classes editing (tailwind, unocss).
$join('foo', 'bar')
will become
foo bar
,
$join(a, b, ...c)
will become
${a} ${b} ${[...c].join(' ')}
and so on.
I was able to add it like that https://github.com/ap32/sample-site-finsweet-cft-12/blob/main/vite.config.ts#L20, but i don't know how to do that in new configuration.
Another question, will you still use babel for https://github.com/ryansolid/dom-expressions in the future?
GitHub
A Fine-Grained Runtime for Performant DOM Rendering - ryansolid/dom-expressions
GitHub
Statically generated site based on Finsweet Client-First Template 12 - Blog template - ap32/sample-site-finsweet-cft-12
GitHub
Statically generated site based on Finsweet Client-First Template 12 - Blog template - ap32/sample-site-finsweet-cft-12
Was this page helpful?