We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 91743ed commit b83ba18Copy full SHA for b83ba18
1 file changed
src/python.ts
@@ -8,8 +8,8 @@ globalThis.py = await window.loadPyodide().then(async (py) => {
8
py.setDebug("production" !== process.env.NODE_ENV);
9
await py.loadPackage("micropip");
10
const micropip = py.pyimport("micropip");
11
- const coreUrl = new URL(`/py/${wheelInfo.fileName}`, window.location.href);
12
- await micropip.install(coreUrl.href);
+ const coreUrl = `${process.env.PUBLIC_URL}/py/${wheelInfo.fileName}`;
+ await micropip.install(coreUrl);
13
14
return py;
15
});
0 commit comments