3 ms·
Compatibility, longevity, reliability and simplicity are what they bring to the table. Compatible because it is a W3 standard implemented natively by all brows
by petilon 7y ago
Compatibility, longevity, reliability and simplicity are what they bring to the table.
Compatible because it is a W3 standard implemented natively by all browsers (including upcoming Edge). Even if your company has applications built using multiple frameworks (including future frameworks) you can write a component once and reuse it in all applications regardless of framework.
Longevity because this is a W3 standard. Frameworks come and go, but things built natively into the browser are here to stay.
Reliability because of Shadow DOM. You don't have to worry about id clashes, CSS classname conflicts etc when you add a component to an existing page.
Simplicity because there is no SDK or library or framework involved. It takes just a few lines of code to write a web component.
Regarding programming models, it doesn't matter. Web Components behave like built-in HTML elements, and all programming models support HTML Elements.