@autochitect/engine 1.1.6 → 1.1.7

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/engine.wasm CHANGED
Binary file
package/index.browser.mjs CHANGED
@@ -82,6 +82,10 @@ export async function createEngine(wasmSource) {
82
82
  const memoryRef = { current: null };
83
83
  const imports = { wasi_snapshot_preview1: buildWasiImports(memoryRef) };
84
84
 
85
+ if (wasmSource == null) {
86
+ wasmSource = new URL('./engine.wasm', import.meta.url);
87
+ }
88
+
85
89
  let instance;
86
90
  if (wasmSource instanceof WebAssembly.Module) {
87
91
  instance = await WebAssembly.instantiate(wasmSource, imports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@autochitect/engine",
3
- "version": "1.1.6",
3
+ "version": "1.1.7",
4
4
  "description": "A 245KB WebAssembly financial modeling engine. Define cost models in a purpose-built DSL, get instant estimates with full dependency tracing. No server required.",
5
5
  "license": "MIT",
6
6
  "type": "module",