Runkit
Runkit
home page
user forum
new notebook
clone notebook
download notebook
support & documentation
log in
sign up
new notebook
help & feedback
clone this notebook
download this notebook
Sign In
Sign Up
RunKit + npm: bcryptjs
node v10.24.1
endpoint
share
tweet
const bcrypt = require("bcryptjs") const cleartext = 'p45sw0rD' const hash = await bcrypt.hash(cleartext, 16) console.log('Hashed:', hash) const match = await bcrypt.compare(cleartext, hash) console.log('Compare matched:', match)
Created from: https://npm.runkit.com/bcryptjs
Loading…
Clone and edit this document