Switch out sass \w vanilla css #38702
Replies: 2 comments
-
We already use PostCSS, and BTW autoprefixer cannot work outside PostCSS anymore. Modern CSS cannot replace Sass, since it's meant to improve worklow before CSS is served. Think of functions, mixins, maps or lists: this won't land in CSS and are quite useful for us. Take a look at our utilities API or the grid framework: there's no way standard CSS can help us as much as Sass does. On the other hand, we're already levearaging modern CSS features like custom properties, but it needs to be slow: browser support needs to be really, really good and we have to implement things without breaking things. All those CSS shiny things will be used un Bootstrap, if they make sense. |
Beta Was this translation helpful? Give feedback.
-
Hello! Situation probably changed in 2024? |
Beta Was this translation helpful? Give feedback.
-
I know, i know. Crazy idea uh?
Well, let me explain. modern css have came a long way.
css in 2023 have built in things such a css nesting today.
So features like this is all possible
https://preset-env.cssdb.org/features/#nesting-rules
https://chromestatus.com/feature/5800613594529792
even things such as
So by using PostCSS you could get the tomorrows new feature supported today in all browsers.
PostCSS also takes care of autoprefixing things so you don't have too. it have the same browserlist functionallity.
You might not even need a build process for simply testing out things in latest chrome. Only when you want to create a production ready
sass seems to me like something very complicated to get up and running. it's built in dart which is a completely other language than the web. and it requires a build process too.
have a look at https://postcss.org to learn more
Beta Was this translation helpful? Give feedback.
All reactions