bcrypt-promise
Promisify node.bcrypt.js library
Usage
npm install bcrypt-promise
.next()
Example with let bcrypt = ;bcrypt ;
koa
Example with Just use keyword yield
before bcrypt-promise function then get the result.
// require library and initiate koa serverlet bcrypt = ;let koa = ;let app = ;app; // USE LIBRARYapp;
Use try-catch
to handle with errors
try let same = bcrypt; catcherror console;