Using the SDK in browser environment not working
I'm running a browser environment Vue application. When using the SDK it does not work because of "type": "module" in the package.json file. When running with this I get a "reuire not defined". When removing that line manually in the sdk, everything works locally, but this does not work when deploying ofc.
Are there any reason for type module, since AFAIK it just got added in 3.3.8 ->? Any tips on how to get it to work in browser environment?
I also noticed that permutation.ts uses require for blake2b, is it possible to set this up to be browserfriendly?
I had to fork this repo to do the changes and publish my own package. The two "issues" mentioned above seemed to get it working.
- import { default as blake2b} from 'blake2b'; in
permutation.ts - package.json - remove "type": "module"