farm
farm copied to clipboard
[Feature Request]: custom CSS transformer support
What problem does this feature solve?
Vite allows the use of a custom CSS transformer (only lightningcss
as of right now), and having that functionality in Farm would be great.
What does the proposed API look like?
In farm.config.ts
:
css: {
transformer: "lightningcss",
},
Farm is based on plugins, so all transformers should be implemented as a plugin, we won't support css.transformer
, instead, we'll provide a plugin-lightningcss
later
Could https://github.com/lawrencecchen/vite-plugin-lightningcss be used as a base?
Yes, we'll provide a pure rust lightningcss plugin later(maybe this month, and PR welcome)