they're in the array so they can be dynamically generated by the script, instead of pissing them static into the markup where in a production site they'd be a waste of bandwidth for non-scripting users and confusing crap for some screen-readers/braille readers.

Remember, HTML is for MORE than just sighted users with the scripttardery, and scripting only elements can wreak havoc for screen/braille reader software which is why so many websites are broken useless messes just BEGGING To get their asses sued off.

Don't believe me? Ask Dominos and Beyonce. Broken artsy-fartsy "designer" crap knee deep in inaccessible scripttardery, that got them dragged into court.

The Supreme Court telling Dominos to go suck an egg, and setting a rather scary precedent.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store