Top "Custom-element" questions

Custom Elements are a feature of HTML that provide a way for you to build your own fully-featured DOM elements and use them in your HTML markup, CSS stylesheets, and JavaScript code

Are custom elements valid HTML5?

I've been unable to find a definitive answer to whether custom tags are valid in HTML5, like this: <greeting&…

html custom-element
Are Web Components actually useable in IE11 and Edge?

Web Components are the hot new thing, and a true web standard, everybody is talking about them and presumably using …

internet-explorer-11 web-component polyfills custom-element
How to listen for custom events defined web component

I have a custom element my-checkbox that wraps a checkbox, label, styling, etc. When that checkbox is toggled I am …

javascript dom web-component shadow-dom custom-element
How to get list of registered custom elements

I'm trying to detect whether a custom element with a specific name was registered or not. Is there a way …

javascript html w3c web-component custom-element
Difference between constructor and connectedCallback in custom elements v1

I am new to web development and recently I have been seeing much debate and talks about Custom Elements v1. …

javascript html web-component shadow-dom custom-element
Polymer 1.0: Two-way bindings with input elements

Code Consider the following Polymer custom element: <dom-module id="test-element"> <template> <input type="text" value="{{…

javascript polymer custom-element
Uncaught DOMException: Failed to execute 'define' on 'CustomElementRegistry': this name has already been used with this registry

Uncaught DOMException: Failed to execute 'define' on 'CustomElementRegistry': this name has already been used with this registry at http://127.0.0.1:8000/components/@…

polymer web-component custom-element polymer-3.x
How to pass an Array as element's Attribute?

I'm developing for sending an Array as element's attribute. File form-list.html So, for using the element and pass the …

javascript polymer polymer-1.0 custom-element
Failed to construct 'CustomElement' error when JavaScript file is placed in head

I have a custom element defined like so: class SquareLetter extends HTMLElement { constructor() { super(); this.className = getRandomColor(); } } customElements.define("square-letter", …

javascript html custom-element
Uncaught DOMException: Failed to execute 'define' on 'CustomElementRegistry' (Polymer 2.0)

I'm facing this issue while running polymer init on polymer-cli. Uncaught DOMException: Failed to execute 'define' on 'CustomElementRegistry'

polymer web-component polymer-2.x custom-element