virtual-machine 0.0.15 → 0.0.16

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.
@@ -206,12 +206,12 @@ if (!("encodeInto" in cachedTextEncoder)) {
206
206
  };
207
207
  }
208
208
  var WASM_VECTOR_LEN = 0;
209
+ function wasm_bindgen__convert__closures_____invoke__h1c84ab4501de45c0(arg0, arg1) {
210
+ wasm.wasm_bindgen__convert__closures_____invoke__h1c84ab4501de45c0(arg0, arg1);
211
+ }
209
212
  function wasm_bindgen__convert__closures_____invoke__h6709295d3f31b919(arg0, arg1, arg2) {
210
213
  wasm.wasm_bindgen__convert__closures_____invoke__h6709295d3f31b919(arg0, arg1, arg2);
211
214
  }
212
- function wasm_bindgen__convert__closures_____invoke__hdce74b4265fa20da(arg0, arg1) {
213
- wasm.wasm_bindgen__convert__closures_____invoke__hdce74b4265fa20da(arg0, arg1);
214
- }
215
215
  var WasmVmFinalization = typeof FinalizationRegistry === "undefined" ? { register: () => {
216
216
  }, unregister: () => {
217
217
  } } : new FinalizationRegistry((ptr) => wasm.__wbg_wasmvm_free(ptr >>> 0, 1));
@@ -246,6 +246,7 @@ var WasmVm = class {
246
246
  }
247
247
  /**
248
248
  * Get the current network connection status.
249
+ * This checks the actual connection state by seeing if an IP was assigned.
249
250
  * @returns {NetworkStatus}
250
251
  */
251
252
  network_status() {
@@ -268,6 +269,7 @@ var WasmVm = class {
268
269
  }
269
270
  /**
270
271
  * Connect to a WebTransport relay server.
272
+ * Note: Connection is asynchronous. Check network_status() to monitor connection state.
271
273
  * @param {string} url
272
274
  * @param {string | null} [cert_hash]
273
275
  */
@@ -403,6 +405,9 @@ function __wbg_get_imports() {
403
405
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
404
406
  }
405
407
  };
408
+ imports.wbg.__wbg_error_7bc7d576a6aaf855 = function(arg0) {
409
+ console.error(arg0);
410
+ };
406
411
  imports.wbg.__wbg_getReader_b6676f6d8b326942 = function(arg0) {
407
412
  const ret = arg0.getReader();
408
413
  return ret;
@@ -423,6 +428,9 @@ function __wbg_get_imports() {
423
428
  const ret = arg0.length;
424
429
  return ret;
425
430
  };
431
+ imports.wbg.__wbg_log_1d990106d99dacb7 = function(arg0) {
432
+ console.log(arg0);
433
+ };
426
434
  imports.wbg.__wbg_new_1ba21ce319a06297 = function() {
427
435
  const ret = new Object();
428
436
  return ret;
@@ -539,18 +547,18 @@ function __wbg_get_imports() {
539
547
  const ret = getStringFromWasm0(arg0, arg1);
540
548
  return ret;
541
549
  };
542
- imports.wbg.__wbindgen_cast_9f0223d8557fdf20 = function(arg0, arg1) {
550
+ imports.wbg.__wbindgen_cast_9d58885f229d7092 = function(arg0, arg1) {
543
551
  const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__hb099e2ae98169675, wasm_bindgen__convert__closures_____invoke__h6709295d3f31b919);
544
552
  return ret;
545
553
  };
546
- imports.wbg.__wbindgen_cast_c47184c56ac918cb = function(arg0, arg1) {
547
- const ret = makeClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__h5a236a3e5f42ce16, wasm_bindgen__convert__closures_____invoke__hdce74b4265fa20da);
548
- return ret;
549
- };
550
554
  imports.wbg.__wbindgen_cast_d6cd19b81560fd6e = function(arg0) {
551
555
  const ret = arg0;
552
556
  return ret;
553
557
  };
558
+ imports.wbg.__wbindgen_cast_dcd0062a54560c23 = function(arg0, arg1) {
559
+ const ret = makeClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__h9e6008f022b1daec, wasm_bindgen__convert__closures_____invoke__h1c84ab4501de45c0);
560
+ return ret;
561
+ };
554
562
  imports.wbg.__wbindgen_init_externref_table = function() {
555
563
  const table = wasm.__wbindgen_externrefs;
556
564
  const offset = table.grow(4);