TL;DR; Yes, Web Components is a standard ... no polyfills required
- Custom Elements API
- shadowDOM
- Templates
Are the 3 technologies what we also call "Web Components"
each can be used without the other!
- HTML Imports was scrapped
- Some include ES Imports
"Web Components" are a W3C standard and supported in all modern Browsers:
Chrome (and Edge, Brave and others running on Chromium), Safari and FireFox
They are as much a standard as any other ES technology
Don't get misguided by old blogs discussing (what we now call) the "V0" standard; which mainly was a Google lets-throw-something-against-the-wall-and-see-what-sticks party only; with input from Mozilla and Apple.
Web Components V1 (since early 2018) is a solid joint effort by Apple, Mozilla and Google.
Microsoft joined the party when they decided to swap Browser engines and make Edge run on Chromium
(Historically) there are 2 types of Custom Elements:
- Autonomous Custom Elements, extend from
HTMLElement
- Customized Built-In Elements, extends from any HTML Element (eg:
HTMLButtonElement
)
Apple has stated, since 2016, they won't implement the latter! (and most who dig deeper, say Apple is right on this one)
It also worth to note, in august 2019, the W3C signed an agreement that the WHATWG
(that is: Apple + Google + Mozilla + Microsoft) is in charge of all HTML and DOM developments; the W3C will only give final approval on standards.
Setting standards is a slow (but steady!) process, because all 4 companies have to agree now.
But just think... Web History has been nothing but (browser) wars...
have you ever seen co-operation like this in the Webs 30 year history?
So what will the future bring?
One new war is already being fought... oblivious to many developers
Note the one big "front-end" name missing...
and the WHATWG is "By invitation only"
Also read: main differences React, Lit, Web Components