can
Version:
MIT-licensed, client-side, JavaScript framework that makes building rich web applications easy.
29 lines (22 loc) • 651 B
HTML
<two-way-name></two-way-name>
<script type="text/stache" id="demo-html"></script>
<script src="../../node_modules/steal/steal.js" dev-bundle main="@empty" id="demo-source">
import { StacheElement } from "can";
class TwoWayName extends StacheElement {
static view = `
<label>
Name:
<input type="text" value:bind="this.name">
</label>
<p>Given name: {{ this.name }}</p>
<label>
Name:
<input type="text" value:bind="this.name">
</label>
`;
static props = {
name: "Eli"
};
};
customElements.define("two-way-name", TwoWayName);
</script>