How to use nth-child selector in tailwindcss

Viewed 47

i want to select every other element of a some element, for example

<div class="parent">
  <div></div>
  <div></div>
  <div></div>
  <div></div>
</div>

i would like to select the second and fourth div, in css to do that one can do

.parent:nth-child(2n) { ... }

but in tailwind, i did a bit a research and im still stuck, does anyone know how to do such a selection ?

1 Answers
Related