Skip to content
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

Mr browser says this project is blocked by CORS policy #85

Open
ghost opened this issue Aug 26, 2022 · 1 comment
Open

Mr browser says this project is blocked by CORS policy #85

ghost opened this issue Aug 26, 2022 · 1 comment

Comments

@ghost
Copy link

ghost commented Aug 26, 2022

It says:

Access to fetch at 'file://.../node_modules/argon2-browser/dist/argon2.wasm' from origin 'null' has been blocked by CORS policy: Cross origin requests are only supported for protocol schemes: http, data, chrome, chrome-extension, brave, chrome-untrusted, https.
argon2.js:91 GET file:///.../node_modules/argon2-browser/dist/argon2.wasm net::ERR_FAILED
loadWasmBinary @ argon2.js:91
loadModule @ argon2.js:41
argon2Hash @ argon2.js:167
309 Error: TypeError: Failed to fetch
at loadWasmBinary (argon2.js:91:16)
at loadModule (argon2.js:41:23)
at Object.argon2Hash [as hash] (argon2.js:167:16)

I really don't want to have to use live server for testing my project if at all possible... Can this be fixed?

I'm testing on brave (fork of chromium).

EDIT:

Using the bundled version seemed to fix it. But also there's also a typo in your readme, the file is:

    <script src="node_modules/argon2-browser/dist/argon2-bundled.min.js"></script>

not:

    <script src="node_modules/argon2-browser/dist/argon2-bundled.js"></script>

(Also just my personal opinion but why would someone prefer the non-bundled version? Id list the bundled one first).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant