aboutsummaryrefslogtreecommitdiff
path: root/static/stork_config.js
diff options
context:
space:
mode:
Diffstat (limited to 'static/stork_config.js')
-rw-r--r--static/stork_config.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/static/stork_config.js b/static/stork_config.js
new file mode 100644
index 0000000..8e2e11b
--- /dev/null
+++ b/static/stork_config.js
@@ -0,0 +1,13 @@
+var baseUrl = document.querySelector("meta[name='base']").getAttribute("content");
+if (baseUrl.slice(-1) == "/") {
+ baseUrl = baseUrl.slice(0, -1);
+}
+stork
+.initialize(baseUrl + "/stork.wasm")
+.then(() => {
+ console.log("Finished downloading WASM");
+})
+.catch(e => {
+ console.error(e);
+}); // download WASM
+stork.register("stork",baseUrl + "/stork.st");