Closed mohamedafzal03 closed 1 year ago
this is not possible at the moment. maybe this would help in the future: https://github.com/webcomponents/polyfills/tree/master/packages/scoped-custom-element-registry
If you'd like to replace a registered component, you could register a proxy wich then later could replace the implementation.
This is a spec question. It's currently impossible to unregister an element (and there are questions about what that would mean). You can see the spec issue here: https://github.com/WICG/webcomponents/issues/754
Origin page HI to register a custom element, window.customElements.define('my-custom-element', MyCustomElement); I want to unregister a custom element , is there any possibilities? like(window.customElements.undefine('my-custom-element') will be helpful if u guys share your insights.