peggy.go peggy.go - 2 months ago 17
Sass (Sass) Question

Is SASS/SCSS a way to make OOCSS?

i know SASS/SCSS and I know whats object oriented, but can I say that SASS is a way to make CSS object oriented? Please correct me if I am wrong.


It's an interesting question as SASS/SCSS doesn't exactly determine the ability to make CSS object oriented. The CSS you write will. As you know it is simply a layer to pre compile CSS.

You could definitely and rightly so state that by using SASS it makes it easier to create object oriented-like css. It definitely helps as you can individualise classes into files, extend, include etc. and you can import them which helps in creating a closer to modular environment than regular CSS provides.

As SASS compiles to CSS, you really could achieve the same Object Oriented classes without it. But it may help you organise the objects.