tailwindlabs / discuss

A place to ask questions, get help, or share what you've built with Tailwind CSS.
MIT License
171 stars 9 forks source link

Cascade style classes? #473

Open bdrtsky opened 4 years ago

bdrtsky commented 4 years ago

Is there any convenient way to extend Tailwind classes depending on some class on body tag? For example some theme related class. How to have one Tailwind class that will change depending on some parent class?

.dark {
   & .tailwind-class {
    color: black
  }
}

.light {
   & .tailwind-class {
    color: white
  }
}