-
Notifications
You must be signed in to change notification settings - Fork 193
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat!: bun css support #461
base: master
Are you sure you want to change the base?
Conversation
We could also make the bun css option non-default first, and change that, if we find it stable. I have just played around with it, and it didn't show any issues, but maybe there are some. I'm also still looking, if I can somehow replace the external array with an easier alternative, that marks css as internal and everything else as external... |
OH! I have completely missed this. Lets briefly talk before merging. So what exactly is Bun CSS support? Does this mean we can get rid of the heavy Lightning CSS support at some point? Now even? I would love to ditch LCSS because it makes 90% of all dependenices megabyte wise. |
It's basically a rewrite of lightningcss in Zig by the Bun team, and it's included in Bun itself. Yes, we could get rid of lightningcss (on bun). Bun css is not as configurable, but I think the defaults set currently are probably alright. Node should still work, if lcss gets installed locally. (like esbuild) I currently added a cli option, that switches to lightningcss. There's probably still a bit of documentation, that needs to get updated. I still have some issues with the current implementation (e.g. the external array). |
Hard to find any information about this. What happens with nested selectors? Are modern color functions supported? How the minifier works? etc. I really want this to replace Lightning CSS npm requirement. Would make Nue exceptionally slim. Developers could potentially enable LCSS support with local npm install. |
As I said, Bun CSS is basically a rewrite of lightningcss: I think this is the basic browser target, but I'm not sure: I haven't seen any option to enable / disable any feature flags on Note: I dind't get the css bundler to properly work with versions of Bun <1.2, so I changed the engines. I hope to still get it to work, but I can't really promise anything. |
Okay, wow. Looking at the Bun code they seem to be taking CSS seriously. A major Zig engineering project. Happy to merge this and Bun 1.2 requirement is not an issue. I would even depreciate Node for this — not a fan of branching to ESBuild and Lightning CSS just to get Node working. Bun is such a stable product these days. Nue website CSS is a good test framework for this feature: if all looks good, then we're good to go. Thoughts? |
No description provided.