DEV Community

Discussion on: Which CSS library do you prefer and WHY ?

Collapse
 
perpetual_education profile image
perpetual . education • Edited

RE: "aren't you just moving what's not nice to read to another file" - YES! Yes. That is what is happening. It's basically the same thing - but just organized differently. HTML is basically a JavaScript object for all practical purposes (The DOM Node etc) - but it's nature is just messy visually. Especially once you start getting some Vue or Ember attributes everywhere.

RE: component / those are totally part of the spec now. You can use them! But beware, they are display: inline; by default. ; )

Component HTML and CSS side by side
This is a PHP template example

There is two files. And in most cases for us - (Vue / Ember) there ends up being a backing controller type .js file too.

We like the one file for each - otherwise, we'd be on the JSX team.

How do you like to do it?