here's a demo of 2: https://codepen.io/hi_mayank/pen/VwoRxGj
it's not "diffing" like i said in my original post, but it very well could be. setting `shadow.innerHTML` would not recreate slotted elements.
here's a demo of 2: https://codepen.io/hi_mayank/pen/VwoRxGj
it's not "diffing" like i said in my original post, but it very well could be. setting `shadow.innerHTML` would not recreate slotted elements.
two use-cases for #WebComponents that i don't see being talked about enough:
1. micro-micro-frontends using custom elements: you can have different people build different parts of the same page (even using different frameworks), and bring them together using custom elements.
2. stateful diffing using shadow dom: you can swap out HTML of a shadow-tree without losing dom state (e.g. focus or text selection) of slotted elements.
GNU social JP is a social network, courtesy of GNU social JP管理人. It runs on GNU social, version 2.0.2-dev, available under the GNU Affero General Public License.
All GNU social JP content and data are available under the Creative Commons Attribution 3.0 license.