Skip to content

Instantly share code, notes, and snippets.

View KasperAndersson's full-sized avatar
🔵
Vertified

Kasper Andersson KasperAndersson

🔵
Vertified
View GitHub Profile

How to couple Sass and CSS Var

If you use Sass extension, you can work with CSS variables.

First, let's create our css variable.

html, :root
  --MyColor: #5966D2

// :root is not an element for Sass. But you can use html before.