Our CSS isn't opinionated enough. @craigabbott argues that the CSS “class only” ...

@stephaniewalter@front-end.social

Our CSS isn't opinionated enough.
@craigabbott argues that the CSS “class only” approach is nice, but it also makes it easy to build things that are not accessible. For example: make a div look like a button. He proposes to style the HTML tags and ARIA attributes directly (like button or [aria-expanded="true"]). This way: developers can’t get the visual, without the proper semantics. Accessibility becomes a side effect of doing it right.

craigabbott.co.uk/blog/2026/ou