4 ms·
Was there ever anything added to HTML that would make <script> tags defined inside a div or other container tag essentially lexically scoped to tags and element
by AtlasBarfed 3y ago
Was there ever anything added to HTML that would make <script> tags defined inside a div or other container tag essentially lexically scoped to tags and elements only within that div?
One of the values of frames was that it did that. Most "portal" frameworks I've seen are nightmares of spaghetti code trying to route around this, and it prevents any true fragment-consumption without the iframe.
It also would allow likely a lot more "rich widgets" where a mess of javascript was contained only in the section of the HTML document needed by that widget, so a library/zoo/collection of widgets could be safely put together.
- rezonant 3y agoThis is pretty much what Web components is