Awesome! Polymer is the best way to create web components that are cross-browser compatible. The API is somewhat different, but they are much more usable!
connectedCallback is called when the custom element is first connected to the document's DOM (according to the MDN documentation). So the container mounts to the DOM, then connectedCallback is triggered.
Pellentesque nec neque ex. Aliquam at quam vitae lacus convallis pulvinar. Mauris vitae ullamcorper lacus. Cras nisi dui, faucibus non dolor quis, volutpat euismod massa. Donec et pulvinar erat.
connectedCallback is called every time, when an element is attached to document, so also when you move an element from one parent to another. MDN definition:
connectedCallback: Invoked each time the custom element is appended into a document-connected element. This will happen each time the node is moved, and may happen before the element's contents have been fully parsed.
Awesome! Polymer is the best way to create web components that are cross-browser compatible. The API is somewhat different, but they are much more usable!
connectedCallback
is called when the custom element is first connected to the document's DOM (according to the MDN documentation). So the container mounts to the DOM, thenconnectedCallback
is triggered.WebReflection on GitHub has a cross browser compatible polyfill of document.registerElement
connectedCallback
is called every time, when an element is attached to document, so also when you move an element from one parent to another. MDN definition:(developer.mozilla.org/en-US/docs/W...)