What do you want to save?
Add Code snippet
New code examples
-
Javascript 2021-09-10 09:00:04
how to hash password in node js
npm i bcrypt const bcrypt = require('bcrypt'); async function hashIt(password){ const salt = await bcrypt.genSalt(6); const hashed = await bcrypt.hash(password, salt); } hashIt(password); // compare the password user entered with hashed pass. async f... Add solution