Skip to content

Parse npm dependencies to show license and other useful information.

License

Notifications You must be signed in to change notification settings

Oberhauser-Dev/npm-license-parser

Repository files navigation

npm-license-parser

Parse infos and licenses of npm dependencies to json format for displaying

Usage (TODO to be verified)

CLI

npm i npm-license-parser -g

or

npm install npm-license-parser --save-dev

Add to scripts to be executed after npm install:

"scripts": {
    "postinstall": "npm-license-parser --onlyDirectDependencies --json src/path/licenses.json"
  }

API

npm i npm-license-parser

import LicenseParser from "npm-license-parser"

const options = {
  exclude: ['.'],
  json: 'licenses.json',
  onlyDirectDependencies: true,
  start: ['./'],
  unknown: true,
};
const parser = new LicenseParser(options);
parser.parse()

About

Parse npm dependencies to show license and other useful information.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published