@volter/tabnode 0.5.18 → 0.5.19

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.
@@ -21103,17 +21103,10 @@ var implementation$1 = function bind2(that) {
21103
21103
  var implementation = implementation$1;
21104
21104
  var functionBind = Function.prototype.bind || implementation;
21105
21105
  var functionCall = Function.prototype.call;
21106
- var functionApply;
21107
- var hasRequiredFunctionApply;
21108
- function requireFunctionApply() {
21109
- if (hasRequiredFunctionApply) return functionApply;
21110
- hasRequiredFunctionApply = 1;
21111
- functionApply = Function.prototype.apply;
21112
- return functionApply;
21113
- }
21106
+ var functionApply = Function.prototype.apply;
21114
21107
  var reflectApply = typeof Reflect !== "undefined" && Reflect && Reflect.apply;
21115
21108
  var bind$2 = functionBind;
21116
- var $apply$1 = requireFunctionApply();
21109
+ var $apply$1 = functionApply;
21117
21110
  var $call$2 = functionCall;
21118
21111
  var $reflectApply = reflectApply;
21119
21112
  var actualApply = $reflectApply || bind$2.call($call$2, $apply$1);
@@ -21233,7 +21226,7 @@ var hasSymbols = requireHasSymbols()();
21233
21226
  var getProto = requireGetProto();
21234
21227
  var $ObjectGPO = requireObject_getPrototypeOf();
21235
21228
  var $ReflectGPO = requireReflect_getPrototypeOf();
21236
- var $apply = requireFunctionApply();
21229
+ var $apply = functionApply;
21237
21230
  var $call = functionCall;
21238
21231
  var needsEval = {};
21239
21232
  var TypedArray = typeof Uint8Array === "undefined" || !getProto ? undefined$1 : getProto(Uint8Array);
@@ -21874,7 +21867,7 @@ function requireApplyBind() {
21874
21867
  if (hasRequiredApplyBind) return applyBind;
21875
21868
  hasRequiredApplyBind = 1;
21876
21869
  var bind3 = functionBind;
21877
- var $apply2 = requireFunctionApply();
21870
+ var $apply2 = functionApply;
21878
21871
  var actualApply$1 = actualApply;
21879
21872
  applyBind = function applyBind2() {
21880
21873
  return actualApply$1(bind3, $apply2, arguments);
@@ -78395,7 +78388,8 @@ function __substratePackageIdentity(vfs2, file) {
78395
78388
  function __webStreamsModule() {
78396
78389
  const module = {};
78397
78390
  for (const name of ["ReadableStream", "ReadableStreamDefaultReader", "ReadableStreamBYOBReader", "ReadableStreamBYOBRequest", "ReadableByteStreamController", "ReadableStreamDefaultController", "TransformStream", "TransformStreamDefaultController", "WritableStream", "WritableStreamDefaultWriter", "WritableStreamDefaultController", "ByteLengthQueuingStrategy", "CountQueuingStrategy", "TextEncoderStream", "TextDecoderStream", "CompressionStream", "DecompressionStream"]) {
78398
- if (typeof globalThis[name] !== "undefined") module[name] = globalThis[name];
78391
+ if (typeof globalThis[name] === "undefined") continue;
78392
+ Object.defineProperty(module, name, { enumerable: true, configurable: true, get: () => globalThis[name] });
78399
78393
  }
78400
78394
  return module;
78401
78395
  }
package/dist/index.mjs CHANGED
@@ -21279,17 +21279,10 @@ var implementation$1 = function bind2(that) {
21279
21279
  var implementation = implementation$1;
21280
21280
  var functionBind = Function.prototype.bind || implementation;
21281
21281
  var functionCall = Function.prototype.call;
21282
- var functionApply;
21283
- var hasRequiredFunctionApply;
21284
- function requireFunctionApply() {
21285
- if (hasRequiredFunctionApply) return functionApply;
21286
- hasRequiredFunctionApply = 1;
21287
- functionApply = Function.prototype.apply;
21288
- return functionApply;
21289
- }
21282
+ var functionApply = Function.prototype.apply;
21290
21283
  var reflectApply = typeof Reflect !== "undefined" && Reflect && Reflect.apply;
21291
21284
  var bind$2 = functionBind;
21292
- var $apply$1 = requireFunctionApply();
21285
+ var $apply$1 = functionApply;
21293
21286
  var $call$2 = functionCall;
21294
21287
  var $reflectApply = reflectApply;
21295
21288
  var actualApply = $reflectApply || bind$2.call($call$2, $apply$1);
@@ -21409,7 +21402,7 @@ var hasSymbols = requireHasSymbols()();
21409
21402
  var getProto = requireGetProto();
21410
21403
  var $ObjectGPO = requireObject_getPrototypeOf();
21411
21404
  var $ReflectGPO = requireReflect_getPrototypeOf();
21412
- var $apply = requireFunctionApply();
21405
+ var $apply = functionApply;
21413
21406
  var $call = functionCall;
21414
21407
  var needsEval = {};
21415
21408
  var TypedArray = typeof Uint8Array === "undefined" || !getProto ? undefined$1 : getProto(Uint8Array);
@@ -22050,7 +22043,7 @@ function requireApplyBind() {
22050
22043
  if (hasRequiredApplyBind) return applyBind;
22051
22044
  hasRequiredApplyBind = 1;
22052
22045
  var bind3 = functionBind;
22053
- var $apply2 = requireFunctionApply();
22046
+ var $apply2 = functionApply;
22054
22047
  var actualApply$1 = actualApply;
22055
22048
  applyBind = function applyBind2() {
22056
22049
  return actualApply$1(bind3, $apply2, arguments);
@@ -38081,7 +38074,8 @@ function __substratePackageIdentity(vfs2, file) {
38081
38074
  function __webStreamsModule() {
38082
38075
  const module = {};
38083
38076
  for (const name of ["ReadableStream", "ReadableStreamDefaultReader", "ReadableStreamBYOBReader", "ReadableStreamBYOBRequest", "ReadableByteStreamController", "ReadableStreamDefaultController", "TransformStream", "TransformStreamDefaultController", "WritableStream", "WritableStreamDefaultWriter", "WritableStreamDefaultController", "ByteLengthQueuingStrategy", "CountQueuingStrategy", "TextEncoderStream", "TextDecoderStream", "CompressionStream", "DecompressionStream"]) {
38084
- if (typeof globalThis[name] !== "undefined") module[name] = globalThis[name];
38077
+ if (typeof globalThis[name] === "undefined") continue;
38078
+ Object.defineProperty(module, name, { enumerable: true, configurable: true, get: () => globalThis[name] });
38085
38079
  }
38086
38080
  return module;
38087
38081
  }
@@ -39793,7 +39787,7 @@ class WorkerRuntime {
39793
39787
  this.worker = new Worker(
39794
39788
  new URL(
39795
39789
  /* @vite-ignore */
39796
- "/assets/runtime-worker-C-l9pCp3.js",
39790
+ "/assets/runtime-worker-ChOZScpd.js",
39797
39791
  import.meta.url
39798
39792
  ),
39799
39793
  { type: "module" }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@volter/tabnode",
3
- "version": "0.5.18",
3
+ "version": "0.5.19",
4
4
  "description": "Node's own library, in a browser tab.",
5
5
  "type": "module",
6
6
  "license": "MIT",
package/src/runtime.ts CHANGED
@@ -820,9 +820,14 @@ function __substratePackageIdentity(vfs: VirtualFS, file: string): string | unde
820
820
  }
821
821
 
822
822
  function __webStreamsModule(): Record<string, unknown> {
823
+ // Read when used, not when the engine loads: the engine later wraps the
824
+ // global ReadableStream (Node's closed-promise tracking), and a copy taken
825
+ // here was the unwrapped one, so require('stream/web').ReadableStream was
826
+ // not globalThis.ReadableStream, as it is in Node.
823
827
  const module: Record<string, unknown> = {};
824
828
  for (const name of ["ReadableStream", "ReadableStreamDefaultReader", "ReadableStreamBYOBReader", "ReadableStreamBYOBRequest", "ReadableByteStreamController", "ReadableStreamDefaultController", "TransformStream", "TransformStreamDefaultController", "WritableStream", "WritableStreamDefaultWriter", "WritableStreamDefaultController", "ByteLengthQueuingStrategy", "CountQueuingStrategy", "TextEncoderStream", "TextDecoderStream", "CompressionStream", "DecompressionStream"]) {
825
- if (typeof (globalThis as Record<string, unknown>)[name] !== "undefined") module[name] = (globalThis as Record<string, unknown>)[name];
829
+ if (typeof (globalThis as Record<string, unknown>)[name] === "undefined") continue;
830
+ Object.defineProperty(module, name, { enumerable: true, configurable: true, get: () => (globalThis as Record<string, unknown>)[name] });
826
831
  }
827
832
  return module;
828
833
  }