grunt-npm-validate v1.2.3
grunt-npm-validate
Grunt task for validating NPM packages.
Getting Started
If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:
npm install grunt-npm-validate --save-dev
Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:
grunt.loadNpmTasks('grunt-npm-validate');
npm-validate task
Run this task with the grunt npm-validate
command.
Task targets, files and options may be specified according to the grunt Configuring tasks guide.
Options
The following options are available:
file
- Type:
String
- Default value:
grunt.config('pkgFile') || 'package.json'
If this filename is specified, the specified file will be validated.
force
- Type:
Boolean
- Default value:
false
Set force to true to report errors but not fail the task.
strict
- Type:
Boolean
- Default value:
false
Set strict to true to fail on warnings as well as errors.
Usage Examples
'npm-validate': {
file: 'package.json'
}