Created
April 2, 2019 11:00
-
-
Save desaijay315/749d4af9570ab54acf81de9204bfb7aa to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const myfunc = async () =>{ | |
| const password = 'Red12345' | |
| const hashedPassword = await bcrypt.hash(password, 8) | |
| console.log(password); | |
| console.log(hashedPassword); | |
| //if a give password amtch the hash passwrod | |
| const isMatch = await bcrypt.compare('Red12345', hashedPassword) | |
| console.log(isMatch); | |
| } | |
| myfunc() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment