seriously, i'm sure it's getting created by some terrible React framework or whatever, but it is incredibly bad and it needs to be fixed.
it's always seemed really strange to me how HTML didn't (somehow) enforce better nesting of tags—first you have the confusion of some things needing paired open-close tags and other things not. and then you've got the fact that closing tags wander all over the place and it seems to be accepted that the browser ought to deal with them the best they can—why didn't HTML enforce stricter grammar? ~Chara
ah! we have context on this, since we saw it happen
so the thing to understand about the web's rise to prominence is that it was driven by the feud between Netscape Navigator and Internet Explorer, each trying to hard to gain a monopoly through rapid addition of features. in the early days, lots of non-technical people were making websites, because the standards for what a site had to look like were a lot looser and the tools were a lot less complicated. (also: the higher standards and more complicated tools we have today have very little benefit to anyone except corporations. not no benefit - in particular, accessibility is slightly better now - but very little. but that's beside the point.)
so it turned out that when you turn millions of people loose on a thing, they don't manage to adhere to any clear syntax rules. there were all sorts of non-paired tags and bad nesting and stuff.
and remember, both of these browsers, though free in monetary terms, were driven by a profit motive - Netscape made enormous money by having a "Netscape Now" button which users would click and it would take them to the site of whoever had paid the most money that day; Microsoft simply wanted to tie the web into its network of monopolies in other markets.
so the browsers were highly incentivized to make that broken markup work somehow, so that their users could see all the sites they wanted to see, not just the sites that were written according to the spec, which had strict rules about nesting and stuff even back then.
so they made it work. they made it work by coming up with heuristics, and by constantly adding to those heuristics over time as site authors invented new forms of broken markup.
unfortunately this wound up making things worse for site authors who did want to take time to do things the right way, because those heuristics resulted in everything being a bit unpredictable even when you tried to follow all the rules. eventually the emerging community of web developers got a handle on what was going on, and documented what they called "quirks mode" as best they could for each other. yay them, but it still sucked that it was all constantly changing and that each browser did it differently, so you had to test your site everywhere.
so some people came up with a way to fix that, a new, rigorous standard that site authors could opt in to, that would always have clear tag nesting and closing and all that good stuff. the idea was that everyone who didn't know the right way to do things could keep doing what they'd been doing, and people who wanted reliability could use the new thing. this standard was XHTML.
we haven't asked anyone younger whether they've heard of XHTML. we suspect not? it did not fare well; it was too hard for browser developers to implement, and nobody could actually make use of it until browsers supported it. by this point there were quite a few more browsers, and the market was divided amongst them, so having stuff work in just one browser was no longer an option. our memory is failing us as to whether Netscape was still a going concern at this point, and whether Firefox had risen from its ashes yet, but in the big picture it doesn't matter. the point is that, to the extent anyone implemented XHTML, it was incomplete and buggy.
also, it turned out that even the paid professionals whose job was to do things the right way found it arduous to close tags correctly every time. the verbosity of the angle-bracket syntax compared to curly braces probably had something to do with that, in our personal view, but it's too late to change now and it doesn't matter anymore. besides, people feel affection for that syntax (we even feel it, a bit) and we don't want to take that away from them.
so anyway XHTML never got used much, and everything was terrible for a while. then! HTML5 came along. in HTML5 everyone said, well, okay we're going to do the quirky thing of trying to fix broken tags, but we're going to do it in a well documented way that's the same on every browser.
this worked! HTML5 succeeded at its mission. now everything is terrible in the same way everywhere. how thrilling!