DEV Community

loading...

Discussion on: Vanilla JavaScript and HTML - No frameworks. No libraries. No problem.

Collapse
john_papa profile image
John Papa Author

Stencil is cool. Template is powerful and I wish html imports would materialize.

But really the pint of this article is just to appreciate what we have. Ya know?

Collapse
efrapp profile image
Efrain Pinto Ponce

When you say “I wish ...” is it because there isn’t a way to do that right now?

Thread Thread
john_papa profile image
John Papa Author

HTML Imports is not supported in most browsers and not trending that way from what I can tell. caniuse.com/#feat=imports

Thread Thread
efrapp profile image
Efrain Pinto Ponce

Ok John, thanks for replay.

Collapse
squidbe profile image
squidbe

HTML Imports is not supported in most browsers and not trending that way from what I can tell

A few years ago, I used them extensively and had hoped that they'd become a standard, but they are, in fact, dead. The only major browser that still supports them is Chrome (Opera does, but, well... it's Opera), and they said that support is ending Feb. 2020. And polyfills won't work unless you purposely stay on version 1.x of webcomponents.js, which you shouldn't (github.com/webcomponents/polyfills...).