HTML Imports
» see w3.org/TR/html-imports/ as it lived, on the wayback machine
~ the obit ~
HTML Imports was one line of markup. You put <link rel="import" href="card.html"> in the head of a document and the browser fetched that file, parsed it as HTML, ran whatever script was inside it and handed the result to the importing page. A component could then be a file, its markup sitting next to the behavior that drove it, delivered by the same mechanism that already delivered stylesheets. For about four years that was the most comfortable way to build on the web platform rather than on a framework.
It shipped on by default in Chrome 36 on 16 July 2014, alongside the first versions of Custom Elements and Shadow DOM. The specification was edited by Dimitri Glazkov and Hajime Morrita, both at Google, and published by the W3C's Web Components working group.
The other engines never arrived. Mozilla declared no plans to implement it and Apple's position was no warmer, so any site using imports had to carry a polyfill for every browser except one. It stayed in that condition for the whole of its life in Chrome: shipping in production, and dependent on a shim everywhere else.
The number that ended it was small and large at once. When Google filed to remove the v0 APIs in July 2018, HTML Imports was running on roughly two percent of Chrome page loads, with Polymer v1 accounting for about 1.9 percent on its own. Two percent of Chrome is an enormous number of page views and a rounding error in a standards argument, and both readings were true. My own work has never had a browser in it at all, since the boards I target do not run one, so I followed this fight through release notes rather than through anything I had to migrate.
~ the rap sheet ~
| Born | 16 July 2014, on by default in Chrome 36 |
|---|---|
| Peak | about 2 percent of Chrome page loads in mid-2018 |
| Killed | 4 February 2020, Chrome 80 |
| Lifespan | 5 years, 7 months in a shipping browser |
| Made by | Dimitri Glazkov and Hajime Morrita at Google |
| Killed by | ES modules, plus two vendors that never implemented it |
~ how it landed ~
Polymer was the reason anybody cared. Google's component library was built on imports from the start, and Polymer 1.0 was the thing that put web components into production at YouTube and across a long tail of enterprise apps. If you shipped Polymer, you shipped imports, whether or not you had an opinion about the tag.
That coupling is also what made the deprecation slow. On 2 May 2018 the Polymer team published its roadmap moving Polymer 3.0 from HTML Imports to ES modules and from Bower to npm, and recommended LitElement for new work, twenty-one months before the removal actually landed.
~ the engines that said no ~
The objection was never that imports did not work. It was that the web already had a module system coming, and bolting a second loader onto <link> meant two ways to fetch and order dependencies, with different caching and different error behavior. ES modules landed in every major browser between 2017 and 2018 and closed the argument by existing.
~ the removal that kept slipping ~
Hayato Ito filed the intent to deprecate and remove Shadow DOM v0, Custom Elements v0 and HTML Imports on 30 July 2018, with usage figures attached and a target of Chrome 73 in April 2019. Chris Harrelson approved it on 7 August. Chrome 70 shipped the deprecation warnings on 16 October 2018, and the Polymer blog told everyone the date two weeks before that.
Then the date moved. Enough developers asked for migration time that the removal slid past M73 and landed in Chrome 80 on 4 February 2020, under a flat line in the release notes: "Web Components v0 are now removed from Chrome." Even that was not the end of the tail. A reverse origin trial let registered sites keep the old APIs through Chrome 87, so Chrome 88, on 19 January 2021, was the first build in which no amount of paperwork would bring imports back.
~ the tombstone the w3c published ~
On 15 June 2023 the W3C republished the specification with a new status: Discontinued Draft. The boilerplate is unusually direct for a standards body. "Publication as a Discontinued Draft implies that this document is no longer intended to advance or to be maintained. It is inappropriate to cite this document as other than abandoned work." The document is still there, editors' names at the top, three years after the last browser that implemented it stopped.
~ leave a rose ~
an anonymous tribute. one rose per visitor per day.
@}-->-- ... roses left here
~ leave a wreath ~
a rose fades by morning. a wreath stays on this grave for good, with your name on it.
paid once through stripe. payments are handled by OÜ Lakeview, the small company that keeps rip.so running. the money pays for the hosting and the nightly digging. adopt it and the headstone reads "maintained in memory by" you. the groundskeeper plants new wreaths at the next tending, usually within a day.
» one email a week: new graves and the anniversaries of the dead. subscribe
other protocols: Visa Touch / Smartplus, Symbios Logic, Google Web APIs, MBone
also died in the 2020s: Firefox Reality, SeatGuru, OpenGrey
~ leave a note ~
visitors before you have left these graveside notes. anonymous welcome.