-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
67 lines (59 loc) · 2.01 KB
/
index.html
File metadata and controls
67 lines (59 loc) · 2.01 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>hyperstream browser example</title>
<link rel="stylesheet" href="./style.css">
</head>
<body>
<main class="page">
<h1>hyperstream browser example</h1>
<p>
Hyperstream is now usable in the browser thanks to
<a
href="https://developer.mozilla.org/en-US/docs/Web/API/Streams_API"
>web streams</a>.
</p>
<section class="columns">
<div class="column">
<h2>Input</h2>
<label for="templateInput">HTML template</label>
<textarea
id="templateInput"
class="editor"
spellcheck="false"
></textarea>
<label for="contentInput">Input content (JSON)</label>
<textarea
id="contentInput"
class="editor"
spellcheck="false"
></textarea>
</div>
<div class="column">
<h2>Transform</h2>
<label for="transformInput">JS transform function</label>
<textarea
id="transformInput"
class="editor"
spellcheck="false"
></textarea>
<div class="controls">
<substrate-button id="runButton" type="button">
start hyperstreaming
</substrate-button>
</div>
</div>
</section>
<section class="result">
<h2>Output HTML</h2>
<pre id="output" class="output"></pre>
<pre id="error" class="error" hidden></pre>
<h2>Rendered result</h2>
<div id="live" class="live"></div>
</section>
</main>
<script type="module" src="./index.ts"></script>
</body>
</html>