webrobert's avatar

tailwind: responsive on element vs screen?

So the general responsive utility is based on the screen width...

<!-- Width of 16 by default, 32 on medium screens, and 48 on large screens -->
<img class="w-16 md:w-32 lg:w-48" src="...">

I want to show hide elements NOT based on screen but based on the width of the parent div.

Does tailwind have a utility for that?

0 likes
1 reply

Please or to participate in this conversation.