Looking through the A-Frame source, I spot that the library sets several meta tags with JavaScript.
This should be safe in A-Frame's case: Mozilla recommend that their library is imported as a blocking, synchronously loaded script in the <head>
, so this work will always happen before we exit <head>
parsing.
Still, it got me thinking: what happens if one changes meta tags with JavaScript in an async script, or after DOMContentLoaded
?
Some specific questions:
<head>
parsing / DOM materialisation? Will they still 'do things' to the page?is there any guarantee in the specs that browsers should respect meta tag mutations?
They are DOM elements, like any other.
The specs won't mention anything specific because they aren't special cases.
are there known issues with getting a browser to recognise meta tag changes after
<head>
parsing / DOM materialisation?
Not from the POV of examining them in the DOM afterwards.