This module is an interface layer for htmllint.
Install
$ npm install gulp-htmllint --save-dev
Usage
var gulp = htmllint = fancyLog = colors = ; gulp; { if issueslength > 0 issues; processexitCode = 1; }
Options
options.rules
Type Object
Default value: (will parse options.config
if not set)
Object containing htmllint options.
options.config
Type: String
Default value: .htmllintrc
Configuration file containing htmllint options.
options.plugins
Type: Array
Default value: []
An array of strings, each of which should be the name of an htmllint plugin to require and use.
options.failOnError
Type: Boolean
Default value: false
Boolean value to define if the process should exit with a code of 1 on htmllint errors.
Custom Reporter
The custom reporter is a function which accepts 2 parameters: filepath and an array of issues as returned by the htmlling-plugin.
Results
Add the property htmllint to the file object, which is available to streams that follow the htmllint stream. The property htmllint has the following format:
"success": false // or true for passing htmllint successfully "issues": // an array of issues as returned by htmllint