Web Components

Stop Comparing Web Components to React: The Trap of Library-Centric Criticism

The realm of web development is teeming with choices, each technology vying for developers’ attention. On one hand, powerful libraries like React have revolutionised how we build web applications. On the other, there are Web Components—although not as “foundational” as one might think, given that they’ve been universally supported by browsers only since 2020. Yet, they are increasingly important in the modern web ecosystem. With its massive ecosystem and community, React often becomes the yardstick against which other technologies are measured. This is especially true for Web Components. However, this comparative framework is unfair and fosters misleading criticisms stemming from overreliance on libraries like React. This post aims to disentangle these misplaced critiques and highlight why Web Components deserve to be evaluated on their own merits.

Embracing Web Components

I have been working with the web for a long time now. And like every other developer, I use frameworks and libraries to build most of my web applications. Over the years as web standards have emerged and solidified over the years, the web platform has become much more capable. One such standard is Web Components. The ability to natively create components using APIs that ship in all modern browsers without needing build tooling or npm installation. I have been diving head-first into Web Components lately, thanks to my friend Rob Eisenberg (notably known for this work on Durandal, Aurelia and FAST at Microsoft).