logoalt Hacker News

gf000yesterday at 9:47 PM1 replyview on HN

> let me add a div so I have a place for my CSS class

As opposed to what exactly? HTML doesn't let you lay out stuff properly without at least some structural divs that have no meaning.

If we have the proper aria properties for example, why does it really matter if I have extra divs (which is, again, irrespective of tailwind)


Replies

TonyAlicea10today at 2:03 AM

I can do a lot of layout without divs. Adding aria to divs is an anti-pattern and likely a worse experience than semantic elements.

You might need some extra divs for layout sure. But I guarantee less than most people are using if they markup their content first.

Remember divs mean nothing. So the opening example on the Tailwind website is the accessible equivalent of “blah blah blah”.