49 lines
827 B
JSON
49 lines
827 B
JSON
{
|
|
"html": {
|
|
"prefix": "html",
|
|
"body": [
|
|
"html(`$1`);"
|
|
],
|
|
"description": "Create a DOM node"
|
|
},
|
|
|
|
"dom": {
|
|
"prefix": "dom",
|
|
"body": [
|
|
"dom;"
|
|
],
|
|
"description": "Use the DOM collection of functions"
|
|
},
|
|
|
|
"*element": {
|
|
"prefix": "*element",
|
|
"body": [
|
|
"class Index extends HTMLElement {",
|
|
"",
|
|
" css = /*css*/ `",
|
|
" index-el {",
|
|
" ",
|
|
" }",
|
|
" `",
|
|
"",
|
|
" html = /*html*/ `",
|
|
" `",
|
|
"",
|
|
" constructor() {",
|
|
" super();",
|
|
" addStyle(this.css);",
|
|
" this.innerHTML = this.html;",
|
|
" }",
|
|
"",
|
|
" connectedCallback() {",
|
|
" ",
|
|
" }",
|
|
"",
|
|
"}",
|
|
"",
|
|
"customElements.define('index-el', Index);",
|
|
"export default Index;"
|
|
],
|
|
"description": "Custom Element Template"
|
|
}
|
|
} |