-
Notifications
You must be signed in to change notification settings - Fork 2
/
example.html
36 lines (36 loc) · 1.76 KB
/
example.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<html>
<head>
<script async src="https://ga.jspm.io/npm:es-module-shims@1.8.2/dist/es-module-shims.js" crossorigin="anonymous"></script>
<script type="importmap">
{
"imports": {
"phx-live-state": "https://ga.jspm.io/npm:phx-live-state@0.11.2/build/src/index.js",
"sprae": "https://ga.jspm.io/npm:sprae@8.1.3/src/index.js",
"template-parts": "https://ga.jspm.io/npm:template-parts@1.0.5/template-parts.js",
"templize/templize.js": "https://ga.jspm.io/npm:templize@2.4.4/templize.js",
"wc-context": "https://ga.jspm.io/npm:wc-context@1.0.0/core.js"
},
"scopes": {
"https://ga.jspm.io/": {
"@preact/signals-core": "https://ga.jspm.io/npm:@preact/signals-core@1.5.1/dist/signals-core.module.js",
"element-props": "https://ga.jspm.io/npm:element-props@2.6.0/element-props.js",
"json-joy/esm/json-patch": "https://ga.jspm.io/npm:json-joy@1.19.0/esm/json-patch/index.js",
"phoenix": "https://ga.jspm.io/npm:phoenix@1.6.15/priv/static/phoenix.mjs",
"process": "https://ga.jspm.io/npm:@jspm/core@2.0.1/nodelibs/browser/process.js",
"reflect-metadata": "https://ga.jspm.io/npm:reflect-metadata@0.1.14/Reflect.js",
"sube": "https://ga.jspm.io/npm:sube@2.3.0/sube.js",
"subscript": "https://ga.jspm.io/npm:subscript@7.5.5/subscript.js",
"subscript/parse.js": "https://ga.jspm.io/npm:subscript@7.5.5/parse.js"
}
}
}
</script>
<script type="module" src="./src/live-template.js"></script>
</head>
<live-template url="ws://localhost:4000/socket" topic="todo:all">
<ul>
<li :each="todo in todos" :text="todo"></li>
</ul>
<button :onclick="sendEvent('bob', event)">butt</button>
</live-template>
</html>