SolidJSS
SolidJS2y ago
4 replies
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 - ryansolid/dom-expressions: A Fine-Grained Runtime for Perf...
GitHub
Statically generated site based on Finsweet Client-First Template 12 - Blog template - ap32/sample-site-finsweet-cft-12
sample-site-finsweet-cft-12/vite.config.ts at main · ap32/sample-si...
GitHub
Statically generated site based on Finsweet Client-First Template 12 - Blog template - ap32/sample-site-finsweet-cft-12
sample-site-finsweet-cft-12/macro/join/index.ts at main · ap32/samp...
Was this page helpful?