Day 2 of 100DaysOfSpec, Common Infrastructure
I am reading and taking notes on the HTML specifications for 100 days as part of #The100DayProject. Read the initial intent/backstory. I am a Microsoft employee but all opinions, comments, etc on this site are my own. I do not speak on behalf of my employer, and thus no comments should be taken as representative of Microsoft’s official opinion of the spec. Subsections not listed below were read without comment.
2 Common Infrastructure
When writing up documentation, there’s a (valid) temptation to write a different version of the document for each distinctive user type. The authors of the HTML spec probably don’t have that luxury—i.e. it’s trouble enough getting everyone to agree on just one document—so the HTML spec covers the concerns of both web devs working on websites, and browsers that need to adhere to the new standards.
It probably does make sense, though, to pay attention to what the other side needs to do. Web browsers can better design for how features are intended to be used; web developers can better grasp how things are working under the hood, and what the responsibilities of the web browser are.
All this is to say that this section seems, at the outset, more oriented towards web browsers as audience.
If you’re following along with these notes, it may be useful to read this section in case any specific ~~ vocab terms ~~ are referenced again.
A feature cannot be considered “supported” if the browser can handle some but not all of its “critical aspects”. The example they use is a browser that knows the dimensions of an MPEG-4 file but doesn’t support the compression format. I mean, makes sense.
2.1.3 DOM trees
“The root element of a
Document object is that
Document’s first element child, if any. If it does not have one then the
Document has no root element.”
Plugins aren’t “child browsing contexts of the
Document” and don’t add any Node objects to the
Document; the example they use is a PDF viewer inside the browser.
The spec actually doesn’t prescribe how user agents (browsers) support and implement plugins, or whether they need to do so at all.