AECC database project.
at master 8 lines 242 B view raw
1class includeHTML extends HTMLElement { 2 connectedCallback() { 3 const src = this.getAttribute("src"); 4 fetch(src).then(response => response.text()).then(data => this.outerHTML = data); 5 } 6} 7 8customElements.define("x-include", includeHTML);