Comments (3)
The code in question is here
Lines 22 to 34 in 7e2e93a
where if the module is supposed to be run under Node.js, the crypto
package is used to obtain proper random numbers. If running under Node.js is not required, I guess the crypto
module can be stubbed out with webpack's second suggestion. Not sure if Node.js meanwhile got their stuff together and made crypto
available globally to match browsers. If not I hope that happens sometime.
from bcrypt.js.
I went with the second option, since trying the first caused a ton more errors. Everything seems to be functional, and the error went away... Being newer to this, I'm not sure there is anything to worry about here.
from bcrypt.js.
Inside: node_modules\bcryptjs\package.json
, update the browser
key to:
"browser": {
"bin": "dist/bcrypt.js",
"crypto": false
},
from bcrypt.js.
Related Issues (20)
- Trailing underscores are not accounted for. HOT 1
- Bcryptjs on browser is not functioning properly. HOT 3
- hopefully can delete email address or write them on the README.md
- Bcryptjs compares badly with jwt and its hash HOT 5
- Error: Illegal arguments: undefined, string HOT 1
- issues with compare/compareSync via docker compose env
- This repository is no longer maintained HOT 5
- How bcryptjs works?
- This library is maintained
- Bcrypt compare always return false HOT 3
- bcryptjs.compare returns illegal arguments error
- Error: Illegal arguments: string, undefined HOT 1
- How to decript password?????? HOT 5
- genSalt not working on nodejs esm
- Unclear license status HOT 2
- Vite: Module "crypto" has been externalized for browser compatibility
- Cannot Import from `bcryptjs` in a Playwright Test HOT 1
- Crypto With Nextjs X.X HOT 2
- Inquiry about the Current Status of the Library HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bcrypt.js.