LearnBoost/stylus — Issue #523: Feature: auto-escape special-characters in selectors
Author: jasonkuhrt
Created: 2012-01-16 15:43:51+00:00
State: open

Large-scale css codebases need special class name patterns that provide better structure. For instance two white-paper-like sites on the topic:

- http://bem.github.com/bem-method/html/all.en.html
- http://smacss.com/

One major problem I see with these systems is the convoluted syntax, i.e.:
- smacss sugests to call layout styles like `.l-` (http://smacss.com/book/type-layout)
- bem suggests to represent bem elements with a class like `__` or `menu__item`

Looking through either it is clear that expressive syntax is a real issue. Yet it shouldn't be since we can use any characters in our selector names!

- http://mathiasbynens.be/notes/html5-id-class
- http://mothereff.in/css-escapes

We could create much nicer class naming systems with more characters. For instance if we wanted bem block-names to be indicated with a class name like `.@