4 ms·
Agreed, and one of the nice things about Web Components is that it makes it practical to build dynamic components for use on multi-page websites since the bandw
by jongjong 3y ago
Agreed, and one of the nice things about Web Components is that it makes it practical to build dynamic components for use on multi-page websites since the bandwidth overhead for including a component into a page is so small (since most of the logic is built into the browser). No need to include an entire framework bundle just to include a small component. For example, I built a dynamic navbar as a Web Component and I just included that component on multiple pages (great for code re-use). All pages loaded instantly. I could never do that with a framework.
I'd never considered to implement a multi-page website navbar as a front-end component before. For code reuse in a multi-page website, one would typically rely on a server-side pre-processing engine (e.g. PHP, ASP.net, ...) but the pervasiveness and lightweight nature of web-components now makes this a possibility.
- troupo 3y ago> All pages loaded instantly. I could never do that with a framework. Of course you could. Depends on framework, but you certainly could.