Skip to content

NOALVO/jwtiny

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jwtiny

Ultra tiny (649 bytes), cross-platform (browser/Node.js) and cross-module (CommonJS/ES2015/AMD) JWT utils: body parser and isExpired method.

Basic usage

  1. Install it using package manager
npm i -S jwtiny
  1. Import it using UMD (CommonJS, ES2015 modules or AMD)
import { parseJwt, isExpired } from 'jwtiny';

const jwtBody = parseJwt('a valid JWT');
// it will be undefined if JWT is not valid

const expired = isExpired(jwtBody);

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%