Three myths about semantic HTML
There is no clever trick in this one, just a handful of decisions worth making deliberately. A few things about semantic HTML that get repeated more often than they get checked.
Code gets read far more often than it gets written, and usually by someone with less context than the author had. It is the sort of thing that looks like polish right up until it costs you an enquiry.
“It only matters for big sites”
The right element gives you behaviour and accessibility for free. Where this goes wrong is almost never a lack of knowledge. Check it against what you would want a competitor's site to get wrong.
“We can deal with it after launch”
Sometimes true, usually expensive. Small and consistent beats large and occasional here.
“Our platform handles it”
Semantic markup is the cheapest accessibility work available. The cost of getting this wrong is rarely visible on the day it happens. Anything you cannot measure here, you are deciding by taste, which is fine as long as everyone knows it.
The short version
The question is rarely whether something can be built, but what it costs to keep running afterwards. Three things worth confirming about semantic HTML before you move on:
- Someone can say what the current setup is without going to look
- A div with a click handler is not a button — and you know whether that is true here
- There is a way to tell whether the last change to this helped
Worth checking on your own setup before it becomes someone else's problem to fix.