~/talk

Unlocking the Power of Shadow DOM

Talkat Conf42 JavaScript 2023 · on Thursday, 2023-11-16· [web-platform, javascript]
linkedin:ankitist
slides:none on file

Defines Shadow DOM as encapsulation used by YouTube, Google Maps and Material UI and shows concrete code: uses attachShadow on a custom element, builds a button inside a shadow root, and toggles closed vs open modes. Demonstrates that open shadow roots are reachable via document.getElementById(...).shadowRoot.querySelector and can have styles changed to green while closed roots throw cannot read property errors and remain blue, proving encapsulation works. Also shows React use on refs and Angular component encapsulation.

AI-written summary · about

  1. 0:00intro
  2. 0:22preamble
  3. 0:34what we will cover
  4. 0:53what is shadow dom
  5. 1:37popular apps using shadow dom
  6. 1:59reactjs
  7. 2:15angular
  8. 2:33demo
  9. 5:28thank you
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.