4 ms·
is it that nice? the beauty of HTML markup is that it's declarative. at least from the tutorials I've seen, WebComponents drag you firmly back into imperative
by bobthepanda 3y ago
is it that nice?
the beauty of HTML markup is that it's declarative. at least from the tutorials I've seen, WebComponents drag you firmly back into imperative land with document.addChild everywhere.
- nine_k 3y agoThe imperative part is required to build a Web Component. When you merely import it. you can use it as declaratively as any other HTML tag. Basically Web COmponents allow you to add your own tags that are rendered as components, and freely mix "built-in" and "custom" DOM nodes in your document.
- sharlos201068 3y agoI'm pretty sure a declarative shadow Dom is currently in the works.