-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6965d36
commit 9335250
Showing
26 changed files
with
58,370 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import init, {WebApp} from './overlay_editor.js'; | ||
|
||
async function run() { | ||
await init(); | ||
console.log('wasm module loaded'); | ||
|
||
const booleanData = await fetch('./tests_boolean.json').then((res) => res.text()); | ||
const stringData = await fetch('./tests_string.json').then((res) => res.text()); | ||
console.log('json files loaded'); | ||
|
||
const app = new WebApp(); | ||
console.log('WebApp starting'); | ||
app.start(booleanData, stringData); | ||
} | ||
|
||
run(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
/* tslint:disable */ | ||
/* eslint-disable */ | ||
export class WebApp { | ||
free(): void; | ||
constructor(); | ||
/** | ||
* @param {string} boolean_data | ||
* @param {string} string_data | ||
*/ | ||
start(boolean_data: string, string_data: string): void; | ||
} | ||
|
||
export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module; | ||
|
||
export interface InitOutput { | ||
readonly memory: WebAssembly.Memory; | ||
readonly __wbg_webapp_free: (a: number, b: number) => void; | ||
readonly webapp_create: () => number; | ||
readonly webapp_start: (a: number, b: number, c: number, d: number, e: number) => void; | ||
readonly __wbindgen_malloc: (a: number, b: number) => number; | ||
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number; | ||
readonly __wbindgen_export_2: WebAssembly.Table; | ||
readonly __wbindgen_export_3: WebAssembly.Table; | ||
readonly closure649_externref_shim: (a: number, b: number, c: number) => void; | ||
readonly _dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hdbe415c98a85d670: (a: number, b: number) => void; | ||
readonly closure662_externref_shim: (a: number, b: number, c: number, d: number) => void; | ||
readonly closure1299_externref_shim: (a: number, b: number, c: number) => void; | ||
readonly closure1516_externref_shim: (a: number, b: number, c: number) => void; | ||
readonly __wbindgen_free: (a: number, b: number, c: number) => void; | ||
readonly __externref_table_alloc: () => number; | ||
readonly __wbindgen_exn_store: (a: number) => void; | ||
readonly __wbindgen_start: () => void; | ||
} | ||
|
||
export type SyncInitInput = BufferSource | WebAssembly.Module; | ||
/** | ||
* Instantiates the given `module`, which can either be bytes or | ||
* a precompiled `WebAssembly.Module`. | ||
* | ||
* @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated. | ||
* | ||
* @returns {InitOutput} | ||
*/ | ||
export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput; | ||
|
||
/** | ||
* If `module_or_path` is {RequestInfo} or {URL}, makes a request and | ||
* for everything else, calls `WebAssembly.instantiate` directly. | ||
* | ||
* @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated. | ||
* | ||
* @returns {Promise<InitOutput>} | ||
*/ | ||
export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>; |
Oops, something went wrong.