17
4

Moving away from Tailwind, and learning to structure my CSS

1mon 2d ago by programming.dev/u/codeinabox in css@programming.dev from jvns.ca

Good to see this kind of articles. Nowadays there are no real reasons anymore for CSS preprocessors.

$colors: (
  primary: blue,
  danger: red
);

@each $name, $color in $colors {
  .text-#{$name} {
    color: $color;
  }
}

Although, rarely used in such a simple example.

Yeah, it’s sad. People forgot how to use CSS properly.

There was (and still is) definitely a push when sass came out to make everything “easier” by making it more complex.