DEV Community

Discussion on: We Should Stop Hating Web Components

Collapse
 
theharshsingh profile image
Harsh Singh • Edited

Yes, but style encapsulation is also presented as its biggest con. but that is not true. developers dont have to use Each and Every technologies of the web component suite. if you dont want style encapsulation then just dont use Shadow DOM at all! and if you are following BEM methodology, you will not see any side-effects. Shadow DOM is just for heavy, self-dependent Web Components. and yes Stencil's DX is almost the same as React. and there are also Hybrids.js and Switzerland.js if you want to write functional web components that are quite similar to the React ones.

Collapse
 
mich profile image
Michel Tobon

Agreed!

Most of thetime I don’t use shadow on my web components but for enclosed design systems I would argue that style encapsulation is really good it does prevent major style collision problems when working at larger scales