Files
gio-patched/apps/gophers/web/index.html
T
2019-05-11 13:17:57 +02:00

28 lines
759 B
HTML

<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, user-scalable=no">
<meta name="mobile-web-app-capable" content="yes">
<script src="wasm_exec.js"></script>
<script>
if (!WebAssembly.instantiateStreaming) { // polyfill
WebAssembly.instantiateStreaming = async (resp, importObject) => {
const source = await (await resp).arrayBuffer();
return await WebAssembly.instantiate(source, importObject);
};
}
const go = new Go();
WebAssembly.instantiateStreaming(fetch("main.wasm"), go.importObject).then((result) => {
go.run(result.instance);
});
</script>
<style>
body,pre { margin:0;padding:0; }
</style>
</head>
<body>
<div id="giowindow"></div>
</body>
</html>