DEV Community

Cover image for What is the future of CSS?
Ben Halpern
Ben Halpern Subscriber

Posted on

What is the future of CSS?

Utility-first CSS is all the rage these days. Does anybody have feelings about what the next evolution of CSS (or web styling in general) will be?

What is on the horizon? Or, at least, what problems still need solving?

Latest comments (49)

Collapse
 
blicat profile image
float • Edited

HTML and CSS are two computer languages that are considered to be "old." They are, nonetheless, still quite important for coders in 2022. HTML and CSS knowledge benefits not just experienced programmers, but also individuals in a range of occupations by providing them with fundamental web page building skills.

Collapse
 
jeremybrett profile image
JeremyBrett
Collapse
 
vickalchev profile image
Vic

I'm surprised to see only one mention of utility libraries like Tailwind. I don't think such libraries are the only way forward but it's interesting to observe how they try to solve existing programs with CSS.

I'd like to see more logic introduced to CSS. We already have that with pseudo-classes but those are pre-written. What if we could create our own logic just like in any other programming languages?

Collapse
 
racheal profile image
Racheal Walker

Hey, I feel this is the future of CSS
Web developers who know CSS are in high demand for businesses. In fact, according to the Bureau of Labor Statistics, web development is a profession expected to grow much faster than the average occupation over the next decade.

Collapse
 
nikhilroy2 profile image
Nikhil Chandra Roy

For some situation, we have to rely svg, canvas but if css new features give us a way to make something like wave effect, clip-path (a better way) it can help us a lot.

Collapse
 
blindfish3 profile image
Ben Calder

Hopefully people actually bothering to learn it properly; instead of relying on the CSS equivalent of JQuery :D

Collapse
 
jaeming profile image
jaeming • Edited

I haven't heard methodologies like BEM and SMACSS mentioned in years. I get the appeal of Tailwind as I like using utility classes in bootstrap. Having stuff like preset padding/margin values is good for consistency. Anyone that has experience with design tokens would probably appreciate Tailwind to a certain extent. But I don't like bloating my HTML with scores of combined classes personally. CSS-in-JS is a big movement that a lot of people are adapting. I'm interested to see in what ways it could impact the way people write and use css in any case.

Collapse
 
fjones profile image
FJones

The quick rise and fall of BEM in particular is fascinating. I'm not sure what killed it. CSS-in-JS? Preprocessing so heavy it made no sense to structure things that way anymore? Frameworks that just broke through with no adherence to BEM? It's an odd one.

Collapse
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

On that day, I would abandon the web.

Collapse
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

With Layers and Scope coming to CSS (hopefully soon), the only thing I feel is missing would be CSS Nesting.

Collapse
 
alohci profile image
Nicholas Stimpson

I wouldn't be surprised if CSS Nesting didn't make it to interoperable implementation before Scope. I think there's far more open questions and implementation complexity to Scope than to Nesting.

Collapse
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

Yes; nesting is really just syntax sugar (as underlined by the fact that many preprocessors have this feature without any hacks to make it work), so it could be implemented relatively quickly.

Collapse
 
sakethkowtha profile image
sakethk • Edited

I feel in future CSS may come up with css components similar to styled-components. We can maintain UI logic and functional logic separate.

Collapse
 
jaeming profile image
jaeming

Exactly. I'm working on a design system with the UX where I work and separating design logic from business logic has a huge appeal in building the component library. It also makes extending/overriding components easy and yet explicit.

Collapse
 
sakethkowtha profile image
sakethk

Awsome @jaeming good to here. Let me know once it come to mature state i will try it.