Skip to content

Instantly share code, notes, and snippets.

@TETRA2000
Created March 25, 2019 14:21
Show Gist options
  • Save TETRA2000/0b51404faa8ddc80d65ab65e89f5e994 to your computer and use it in GitHub Desktop.
Save TETRA2000/0b51404faa8ddc80d65ab65e89f5e994 to your computer and use it in GitHub Desktop.
hello-lit-html
<!DOCTYPE html>
<head>
<meta charset="UTF-8"/>
</head>
<body>
<script type="module">
import {html, render} from './node_modules/lit-html/lit-html.js';
const myTemplate = (name) => html`<p>Hello ${name}</p>`;
render(myTemplate('World'), document.body);
</script>
</body>
{
"name": "hello-lit-html",
"version": "1.0.0",
"description": "",
"main": "index.js",
"dependencies": {
"lit-html": "^1.0.0"
},
"devDependencies": {},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment