-
Notifications
You must be signed in to change notification settings - Fork 506
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
About import.meta.url #326
Comments
Isn't this a bug in the bundling tool you're using? |
I don't think so. The project was built with // my usage
import { ZipReader, HttpReader, TextWriter, BlobWriter } from '@zip.js/zip.js';
// ... // vendors.*.js
// ...
try{un="file:///*/@zip.js+zip.js@2.4.10/node_modules/@zip.js/zip.js/lib/zip-fs.js"}catch(cn){}Y({baseURL:un})
// ... I just want to know is there any way to remove this by config, which I think is no need for web project in browser. try {
baseURL = import.meta.url;
} catch (error) {
// ignored
} If there is no good configurable way to solve this, I may keep the trick solution. |
It's a bug in webpack, here's the links to the corresponding issues webpack/webpack.js.org#6087, webpack/webpack#14445. It looks like it's adjustable though. |
@NNBishoper Did you try to set |
LGTM. I will try it later. Thank you so much. |
You're welcome. I'm closing and moving the issue in the Discussions tab to keep it visible. |
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
Hi.
I use
zip.js
for my web project in browser.Because of this, the bundle contains the env local path like
"file:///*/@zip.js+zip.js@2.4.10/node_modules/@zip.js/zip.js/lib/zip-fs.js"
, which may cause the security issue.Now my solution is to replace
import.meta.url
with''
before build, which is so trick.Is there any way to solve this from your point of view. I think web project in browser is no need for this.
Thank you.
The text was updated successfully, but these errors were encountered: