webpack-nsp-plugin

0.1.0 • Public • Published

Webpack Node Security Platform Plugin

Webpack plugin that runs the Node Security Platform audit on your package.json, package-lock.json or npm-shrinkwrap.json.

NOTE: Webpack plugin is a wrapper for the nodesecurity/nsp package.

Install

npm install --save-dev webpack-nsp-plugin

Usage

In your webpack.config.js

var NspPlugin = require('webpack-nsp-plugin');
 
module.exports = {
    // ...
    plugins: [
      new NspPlugin()
    ]
};

Options:

module.exports = {
    // ...
  plugins: [
    new NspPlugin(options)
  ]
}

options.reporter

Type: String
Default: summary

Defines the output format of the vulnerabilities report. Available (built-in) reporters:

  • table
  • summary
  • json
  • codeclimate
  • minimal

It is possible to install 3rd party reporters from npm or create your own.

For more information, go to nodesecurity/nsp#output-reporters

options.verbose

Type: Boolean
Default: false

Provide more verbose output.

options.quiet

Type: Boolean
Default: false

options.stopOnError

Instruct the build process to continue successfully regardless of errors.

Type: Boolean
Default: true

License

MIT © Guneet Uppal

Package Sidebar

Install

npm i webpack-nsp-plugin

Weekly Downloads

6

Version

0.1.0

License

MIT

Unpacked Size

6.83 kB

Total Files

10

Last publish

Collaborators

  • gunzzblazzing