Cover image for Web Components for Enterprise. Part 2: Nuxeo, Ionic, Vaadin

Web Components for Enterprise. Part 2: Nuxeo, Ionic, Vaadin

Serhii Kulykov on July 23, 2019

Web Components, like almost any technology in the frontend ecosystem, have supporters and opponents. The opinion polarity is mentioned in the annou...
Editor guide
mkrl profile image
Mikhail Korolev

Recently I've been looking into something to replace Polymer components being used in a project I'm working on (funnily enough, we also still actively use the polymer-dependent Vaadin components along with the Polymer 2 itself). And Stencil looked very interesting, with TypeScript an other cool stuff out of the box. However, the sad part turned out to be the fact that Stencil does not allow extending existing components at any point. Inheritance from any imported class is not allowed due to some internal compiler quirks (Stencil is, in fact, a compiler). They have an actively discussed issue and the team did state that they have a good practice for this in mind, but didn't follow up for over 3 months and the decision kind of hang up.

daviddalbusco profile image
David Dal Busco

I was looking to inheritance too when I began to play with Stencil and at first I was sad too that it wasn't possible.

Fast forward one year later, I've created multiple components and I'm even developing a full app only with it (aka "without framework") and turns out I was able to live without that pattern. Also don't feel my code is that uglier.

Just wanted to point out that according my experience, even if that would be cool, it isn't something absolutely mandatory or maybe you've got a concrete use case where inheritance is absolutely must?

adam_cyclones profile image
Adam Crockett

I love the idea of web components, but I don't know if I need them now that the trinity of frontend frameworks exist. But then again, it would be nice not to be tied to a particular framework. Caniuse?

scott_yeatts profile image
Scott Yeatts

All major browsers support the required specs for web components since late last year, except Edge (Chromium Edge should fix that).

I've been building framework-less on Stencil for almost a year now and I have to say... It's AMAZING. I honestly believe web components are what the frameworks have been trying to give us for the last decade.

Now that they are part of the spec and relatively stable, I don't really see the point in the Frameworks anymore, other than to provide an opinionated standard, and access to all the libraries built to support them that don't work outside of their context.

petecarapetyan profile image
Pete Carapetyan

re: your #1 Summary point - "Custom Elements being class based by design as a basic problem for so many people."

I still can’t figure out if this is just a dev preference, or if this spec actually prevents a migration towards the benefits of functional programming?

An example is Java, where class based code hasn’t prevented a migration to functional programming - it’s just one of many preferred options for how I write my Java code. Isn’t that same thing true within the context of WC, as it is currently spec’d?

bmarkov profile image

htmlelements.com/ should be probably in this collection, too. Smart is web components framework built by jQWidgets with more than 60 web components