5 <meta http-equiv=
"Content-Type" content=
"text/html; charset=utf-8">
6 <link rel=
"shortcut icon" href=
"data:image/x-icon;," type=
"image/x-icon">
7 <title>sqlite3 WASM Demo Page Index
</title>
13 flex-direction: column;
17 font-family: monospace;
25 border-radius:
0.25em;
27 .hidden, .initially-hidden {
28 position: absolute !important;
29 opacity:
0 !important;
30 pointer-events: none !important;
31 display: none !important;
33 .warning { color: firebrick; }
35 <header id='titlebar'
><span>sqlite3 WASM demo pages
</span></header>
37 <div>Below is the list of demo pages for the sqlite3 WASM
38 builds. The intent is that
<em>this
</em> page be run
39 using the functional equivalent of:
</div>
40 <blockquote><pre><a href='https://sqlite.org/althttpd'
>althttpd
</a> -enable-sab -page index.html
</pre></blockquote>
41 <div>and the individual pages be started in their own tab.
44 <li>All of these pages must be served via an HTTP
45 server. Browsers do not support loading WASM files via
47 <li>Any OPFS-related pages or tests require:
49 <li>That the web server emit the so-called
50 <a href='https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cross-Origin-Opener-Policy'
>COOP
</a>
52 <a href='https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cross-Origin-Embedder-Policy'
>COEP
</a>
53 headers.
<a href='https://sqlite.org/althttpd'
>althttpd
</a> requires the
54 <code>-enable-sab
</code> flag for that.
56 <li>A very recent version of a Chromium-based browser
57 (v102 at least, possibly newer). OPFS support in the
58 other major browsers is pending. Development and testing
59 is currently done against a dev-channel release of
60 Chrome (v111 as of
2023-
02-
10).
66 <div>The tests and demos...
70 <li><a href='tester1.html'
>tester1
</a>: Core unit and
71 regression tests for the various APIs and surrounding
73 <li><a href='tester1-worker.html'
>tester1-worker
</a>: same thing
74 but running in a Worker.
</li>
75 <li><a href='tester1-esm.html'
>tester1-esm
</a>: same as
76 <code>tester1
</code> but loads sqlite3 in the main thread via
79 <li><a href='tester1-worker.html?esm'
>tester1-worker?esm
</a>:
80 same as
<code>tester1-esm
</code> but loads a Worker Module which
81 then loads the sqlite3 API via an ES6 module. Note that
82 not all browsers permit loading modules in Worker
87 <li>Higher-level apps and demos...
89 <li><a href='demo-
123.html'
>demo-
123</a> provides a
90 no-nonsense example of adding sqlite3 support to a web
91 page in the UI thread.
</li>
92 <li><a href='demo-
123-worker.html'
>demo-
123-worker
</a> is
93 the same as
<code>demo-
123</code> but loads and runs
94 sqlite3 from a Worker thread.
</li>
95 <li><a href='demo-jsstorage.html'
>demo-jsstorage
</a>: very basic
96 demo of using the key-value VFS for storing a persistent db
97 in JS
<code>localStorage
</code> or
<code>sessionStorage
</code>.
</li>
98 <li><a href='demo-worker1.html'
>demo-worker1
</a>:
99 Worker-based wrapper of the OO API #
1. Its Promise-based
100 wrapper is significantly easier to use, however.
</li>
101 <li><a href='demo-worker1-promiser.html'
>demo-worker1-promiser
</a>:
102 a demo of the Promise-based wrapper of the Worker1 API.
</li>
108 #test-list { font-size:
120%; }
110 <script>//Assign a distinct target tab name for each test page...
111 document
.querySelectorAll('a').forEach(function(e
){