planet-wars/frontend/www/bootstrap.js

19 lines
576 B
JavaScript
Raw Normal View History

2019-09-13 20:54:21 +00:00
// A dependency graph that contains any wasm must all be imported
// asynchronously. This `bootstrap.js` file does the single async import, so
// that no one else needs to worry about it again.
2019-09-17 16:27:44 +00:00
// Import index.js that executes index.ts
var h = (a, b) => {}
export function handle(loc, e) {
console.log("handle");
h(loc, e);
}
import ("./index.js")
.then(e => {
console.log(e.handle);
h = e.handle;
})
.catch(e => console.error("Error importing `index.js`:", e));
window.setTimeout(() => handle("static/games/spiral2.json", "spiral2"), 3000);