antelle / argon2-browser

Argon2 library compiled for browser runtime
https://antelle.net/argon2-browser
MIT License
367 stars 79 forks source link

Edge support #36

Closed Alex----- closed 4 years ago

Alex----- commented 4 years ago

Edge does not support the import() function used in lib/argon2.js. Also, https://antelle.net/argon2-browser/ does not work in Edge because TextEncoder is not defined.

antelle commented 4 years ago

Hi! I've fixed the demo in Edge. Most likely you won't load the file like this in production, so import should be used only for making a demo / prototype. You can export loadArgon2WasmModule function to load the file properly in Edge. For TextEncoder/Decoder, you will need a polyfill, which should be bundled separately indeed.