discuss icon indicating copy to clipboard operation
discuss copied to clipboard

Can't get odd, even, first, last... pseudo class

Open endadodev opened this issue 6 years ago • 3 comments

This is my tailwind.config.js:

variants: { backgroundColor: ['responsive', 'group-hover', 'first', 'last', 'odd', 'even', 'hover', 'focus', 'active', 'visited', 'disabled'], },

And this my html: <div v-for="item in itemList" class="border-t text-gray-600 bg-yellow-500 odd:bg-gray-200"> item </div>

Does not work for me any pseudo-class that I add in taildwind.config.css.

Please, help me!

endadodev avatar Oct 31 '19 12:10 endadodev

Hmm should work, are you sure your CSS is being compiled using your Tailwind config?

Here's a working example:

https://tailwind.run/DFcetn

adamwathan avatar Oct 31 '19 12:10 adamwathan

Seems like it requires @tailwindcss/custom-forms. Is that expected?

vascoosx avatar Jan 21 '20 04:01 vascoosx

@vascoosx That's just a default configuration on tailwind.run, not needed for this example.

tlgreg avatar Jan 21 '20 04:01 tlgreg