Pro Tailwind

04. Move CSS vars into plugin

🐇 TL;DR

  • Our plugin is working
  • Let’s port our CSS variables to the plugin!

⬇️ Skip to the challenge


🐢 Background

Now that we have our Tailwind CSS plugin wired up, let’s start consolidating our theming functionality into the plugin.

The first thing we want to do is port the CSS variable declarations from the CSS file to the plugin.

That means we’ll be able to do all our work in one file - and one language!


🏆 Your challenge 🏆

In the Tailwind Play below:

  1. Move the CSS variable declarations from the CSS tab to the plugin defined in the Config tab.

You’ll need to write your CSS using the CSS-in-JS object syntax!

One more time, resist worrying about code duplication for now 😅


✌️ Good luck!

Start challenge