Skip to content

Instantly share code, notes, and snippets.

@Hypercubed
Last active April 16, 2019 16:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Hypercubed/ca40630fa6317183d1d8e1f9cdcfdcb3 to your computer and use it in GitHub Desktop.
Save Hypercubed/ca40630fa6317183d1d8e1f9cdcfdcb3 to your computer and use it in GitHub Desktop.
-/
node_modules/
package-lock.json
module.exports = {
"package_path": "./-/",
"package_root": "/-/"
}
<!doctype html>
<head>
<script type="module">
import { LitElement, css, html } from '/-/lit-element@2.1.0.bundle.js';
class MyElement extends LitElement {
static get properties() {
return {
mood: {type: String}
}
}
static get styles() {
return css`.mood { color: green; }`;
}
render() {
return html`Web Components are <span class="mood">${this.mood}</span>!`;
}
}
customElements.define('my-element', MyElement);
</script>
</head>
<body>
<my-element mood="great"></my-element>
</body>
</html>
{
"name": "@swimlane/airdrop-example",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"airdrop": "airdrop add lit-element@2.1.0 --clean --bundle"
},
"author": "",
"license": "MIT",
"devDependencies": {
"@swimlane/airdrop-cli": "^1.0.0-rc1.6"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment