FredKSchott / rollup-plugin-polyfill-node

A modern Node.js polyfill for your Rollup bundle.
Other
178 stars 57 forks source link

randomBytes missing from crypto even though it is in crypto-browserify #44

Open customautosys opened 2 years ago

customautosys commented 2 years ago

Hi, how do I use crypto such that it has randomBytes? Currently I have an error as crypto$1.randomBytes is undefined.

Or how do I enable the crypto shim? I notice it seems to be disabled and set to an empty path.

I need this to get a module working with Vite, namely, @auth0/cordova.

Thanks a lot!

shreyasminocha commented 2 years ago

I'm just using the randombytes package instead of using crypto.randomBytes. Works fine.