I wanted to try using with Vite, but seems there is a console error:
Uncaught ReferenceError: global is not defined
at node_modules/randombytes/browser.js (browser.js:16:14)
at __require2 (chunk-ASBRWZGP.js?v=88b69488:15:50)
at crypto.js:3:25
Looking the error, seems the randombytes module is not able to get browser global.crypto because it is using global instead of globalThis.
I wanted to try using with Vite, but seems there is a console error:
Looking the error, seems the randombytes module is not able to get browser
global.crypto
because it is usingglobal
instead ofglobalThis
.Any solution?