Modular CSS with LESS
All class names and IDs in CSS are global, which makes it extremely difficult to maintain in large-scale projects. No matter how well you specify your naming conventions, vanilla CSS is a pretty messy language to work with.
Some of the ways we can solve that problem, or at least minimize it, is by implementing CSS preprocessor frameworks, such as Sass and LESS. Both of them are allowing us to separate the style sheets into logical modules (files), create variables, mix in classes, and generate CSS with loops and conditions. At the end of the development cycle, we can compile all the files into one or many plain CSS files before moving the styles to production.
Let's set up a simple Meteor app and implement the same ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access