customElements.define() and lifecycle callbacks
Autonomous custom elements: registration, upgrade and the connected, disconnected and attributeChanged callbacks. Specification: html.spec.whatwg.org/multipage/custom-elements.html.
Results
Probed on 2026-10-19 with Node.js v22.23.3.
warpdom 0.1.6
Supported3 of 3 checks work.
Web IDL existence (coverage):
- CustomElementRegistry: interface present; 5 of 6 members present, missing:
initialize.
happy-dom 21.0.3
Supported3 of 3 checks work.
Web IDL existence (coverage):
- CustomElementRegistry: interface present; 5 of 6 members present, missing:
initialize.
jsdom 30.1.3
Supported3 of 3 checks work.
Web IDL existence (coverage):
- CustomElementRegistry: interface present; 5 of 6 members present, missing:
initialize.
linkedom 0.18.13
Supported3 of 3 checks work.
Web IDL existence (coverage):
- CustomElementRegistry: interface not defined.
Checks
Exists when: window.customElements.define is a function.
connected-disconnected: connectedCallback runs on insertion into the document and disconnectedCallback on removal. (spec)attribute-changed: attributeChangedCallback(name, old, new) runs for attributes listed in observedAttributes only. (spec)upgrade: An element parsed before define() is upgraded when its definition arrives; whenDefined() and get() see it. (spec)