CSS or SCSS This is all new stuff to me feeling lost

CSS or SCSS This is all new stuff to me feeling lost
0

#1

Looking at different peoples product landing page I noticed some people use SCSS on codepen instead of CSS
cant help wondering what the advantages of one over another would be. This is all so new. Any thoughts are much appreciated.
Thank you much.


#2

SCSS helps enforce DRY. (Don’t repeat yourself)

You can declare one style and keep appending variants to the style without needing to type them over and over again. It’s handy especially if you have long names like following BEM methodologies.

It helps with modularity. SCSS allows something called partials. Basically different sets of css codes that can be bundled into one main scss file to easily manage stuff.

Logics. Variable, if statements, loops also helps keep your code short.

There are also other advantages besides this.


#3

Css is the core language, and scss a CSS preprocessor. Preprocessors are like superpowers for CSS. SCSS syntax is translated to CSS.

Advantages of scss
Less code to be written
Some logic can be put to CSS (ifs, variables, etc…)

You can stick to CSS for now and when you’re comfortable, you can go SCSS. :slight_smile:


#4

Thank you both, I appreciate the knowledge.