egg-easy-jwt
jsonwebtoken plugin for Egg.js.
NOTE: This plugin just for integrate jsonwebtoken into Egg.js, more documentation please visit node-jsonwebtoken.
Install
$ npm i --save egg-easy-jwt
Usage & configuration
config/plugin.js
exportsjwt =enable: truepackage: 'egg-easy-jwt'
example
// controller.js or service.jsconst token = await thisctxjwt;const verify = await thisctxjwt;const decode = thisctxjwt;
more example please visit https://github.com/auth0/node-jsonwebtoken.