We are revisiting a 5 year old debate summed up in Chris Coyier's 2019 CSS Tricks article called the Great Divide and looking at what has changed.
What's behind the "Great Divide"?
A worry:
- Over "gatekeeping" and gender bias. If you have to be a programmer accessible routes to web development narrow.
- That web standards will fall?
- That code complexity is a cost to the environment and users.
Why does the divide exist?
- HTML and CSS not meeting the (perceived) component based design needs of the time.
- CSS not seen as easy to scope for large scale team project work.
- Browsers not being trusted. Better to use JS to tell them what to do.
- Marketing (although Meta and Google seem to have lost interest in their React and Angular offerings).
- The amazing real time user interaction JavaScript brought.
CSS frustrates many. Mostly through not learning it, understanding its declarative nature and impatience. Rachel Andrew wrote:
"CSS is simultaneously too easy to bother with, yet so hard it needs to be wrapped up in a ball of JavaScript in case it scares the horses".
Is it getting smaller?
Technology:
- CSS is being rapidly refactored - removing common dependencies on JS (including interactive ones).
- Browsers working together to speed up progress.
- Web components offering a standards based interoperable alternative to 3rd party JS components.
- JS fatigue. Maintaining a complex set of dependencies.
- The Cascade is back with
@layer. @scope and :where()
A move to doing more with less code. - WebAssembly (WASM) - a new web standard with more power than JS.
User demands:
- For web content on their terms. Increasingly removing our visual designs and expecting content on any type of device.
- Frustration with CSS often came from mimicking print.
- The need to deliver fast, green, valid and accessible HTML content.
The WordPress divide
- For those who use a WYSIWYG builder.
- More recently, those who develop themes as WordPress moves from PHP themes to JS block themes.