cojson-core-wasm 0.18.3 → 0.18.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +5 -1
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -4,5 +4,9 @@ import __wbg_init from "./public/cojson_core_wasm.js";
|
|
|
4
4
|
import { data } from "./public/cojson_core_wasm.wasm.js";
|
|
5
5
|
|
|
6
6
|
export async function initialize() {
|
|
7
|
-
|
|
7
|
+
const response = await fetch(data);
|
|
8
|
+
|
|
9
|
+
const arrayBuffer = await response.arrayBuffer();
|
|
10
|
+
|
|
11
|
+
return await __wbg_init({ module_or_path: arrayBuffer });
|
|
8
12
|
}
|