@loaders.gl/polyfills 4.0.0-beta.4 → 4.0.0-beta.6

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/dist/dist.dev.js CHANGED
@@ -37,6 +37,8 @@ var __exports__ = (() => {
37
37
  function fetchNode(path, options) {
38
38
  throw new Error("fetchNode not available in browser");
39
39
  }
40
+ globalThis.process = globalThis.process || {};
41
+ globalThis.process.env = globalThis.process.env || {};
40
42
  return __toCommonJS(index_browser_exports);
41
43
  })();
42
44
  return __exports__;
@@ -3,4 +3,6 @@ export const NodeFileSystem = null;
3
3
  export function fetchNode(path, options) {
4
4
  throw new Error('fetchNode not available in browser');
5
5
  }
6
+ globalThis.process = globalThis.process || {};
7
+ globalThis.process.env = globalThis.process.env || {};
6
8
  //# sourceMappingURL=index.browser.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.browser.js","names":["installFilePolyfills","NodeFileSystem","fetchNode","path","options","Error"],"sources":["../src/index.browser.ts"],"sourcesContent":["// loaders.gl, MIT License\n\nexport function installFilePolyfills() {}\n\n// Dummy export to avoid import errors in browser tests\nexport const NodeFileSystem = null;\n\nexport function fetchNode(path: string, options: RequestInit): Promise<Response> {\n throw new Error('fetchNode not available in browser');\n}\n"],"mappings":"AAEA,OAAO,SAASA,oBAAoBA,CAAA,EAAG,CAAC;AAGxC,OAAO,MAAMC,cAAc,GAAG,IAAI;AAElC,OAAO,SAASC,SAASA,CAACC,IAAY,EAAEC,OAAoB,EAAqB;EAC/E,MAAM,IAAIC,KAAK,CAAC,oCAAoC,CAAC;AACvD"}
1
+ {"version":3,"file":"index.browser.js","names":["installFilePolyfills","NodeFileSystem","fetchNode","path","options","Error","globalThis","process","env"],"sources":["../src/index.browser.ts"],"sourcesContent":["// loaders.gl, MIT License\n\nexport function installFilePolyfills() {}\n\n// Dummy export to avoid import errors in browser tests\nexport const NodeFileSystem = null;\n\nexport function fetchNode(path: string, options: RequestInit): Promise<Response> {\n throw new Error('fetchNode not available in browser');\n}\n\n// Ensure process and process.env are defined, as Node code tends to crash on these\n// @ts-ignore\nglobalThis.process = globalThis.process || {};\n// @ts-ignore\nglobalThis.process.env = globalThis.process.env || {};\n"],"mappings":"AAEA,OAAO,SAASA,oBAAoBA,CAAA,EAAG,CAAC;AAGxC,OAAO,MAAMC,cAAc,GAAG,IAAI;AAElC,OAAO,SAASC,SAASA,CAACC,IAAY,EAAEC,OAAoB,EAAqB;EAC/E,MAAM,IAAIC,KAAK,CAAC,oCAAoC,CAAC;AACvD;AAIAC,UAAU,CAACC,OAAO,GAAGD,UAAU,CAACC,OAAO,IAAI,CAAC,CAAC;AAE7CD,UAAU,CAACC,OAAO,CAACC,GAAG,GAAGF,UAAU,CAACC,OAAO,CAACC,GAAG,IAAI,CAAC,CAAC"}