gulp-rb-validate-html
Advanced tools
Comparing version 0.0.2 to 0.0.3
31
index.js
@@ -31,3 +31,3 @@ /*jslint node: true*/ | ||
if (abort) { | ||
gutil.log('[' + guideline + '] ' + gutil.colors.white(tag + ": ") + gutil.colors.red(mistake)); | ||
gutil.log('[' + guideline + '] ' + gutil.colors.white(tag + ": ") + gutil.colors.red(mistake) + " [FAIL]"); | ||
errorBreak = true; | ||
@@ -254,18 +254,23 @@ } else { | ||
parseHTML(str, options.checkremote); | ||
singleQuotes(str); | ||
bodyStylesheet(str); | ||
if (!str) { | ||
validationError('', 'File is empty or null', 'WARNING', false); | ||
} else { | ||
if (options.checkindent) { | ||
checkIndentation(str, options.indent); | ||
} | ||
parseHTML(str, options.checkremote); | ||
singleQuotes(str); | ||
bodyStylesheet(str); | ||
if (options.checkviewport) { | ||
checkViewport(str); | ||
} | ||
if (options.checkindent) { | ||
checkIndentation(str, options.indent); | ||
} | ||
if (str.includes('<head>') && !str.includes('charset="utf-8"') && !str.includes('charset=utf-8')) { | ||
validationError('Encoding', 'Undefined or wrong encoding, must be: charset="utf-8"', 'CI-FE-2002', true); | ||
if (options.checkviewport) { | ||
checkViewport(str); | ||
} | ||
if (str.includes('<head>') && !str.includes('charset="utf-8"') && !str.includes('charset=utf-8')) { | ||
validationError('Encoding', 'Undefined or wrong encoding, must be: charset="utf-8"', 'CI-FE-2002', true); | ||
} | ||
} | ||
if (error) { | ||
@@ -272,0 +277,0 @@ gutil.log(gutil.colors.cyan("File: " + file.path)); |
{ | ||
"name": "gulp-rb-validate-html", | ||
"version": "0.0.2", | ||
"version": "0.0.3", | ||
"description": "Gulp plugin to check HTML files according to web frontend guidelines", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
11046
239