From 03ad87d651efc95e432873ff2423f1878e4b44e1 Mon Sep 17 00:00:00 2001 From: l50741 Date: Wed, 5 Apr 2017 21:30:22 +0100 Subject: [PATCH] add a grunt plugin to check accessibility --- Gruntfile.js | 9 +++++++++ package.json | 1 + 2 files changed, 10 insertions(+) diff --git a/Gruntfile.js b/Gruntfile.js index 82b4ca3f..cfd66480 100755 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -50,6 +50,7 @@ module.exports = function (grunt) { grunt.loadNpmTasks("grunt-chmod"); grunt.loadNpmTasks("grunt-exec"); grunt.loadNpmTasks("grunt-execute"); + grunt.loadNpmTasks("grunt-accessibility"); // Project configuration @@ -133,6 +134,14 @@ module.exports = function (grunt) { ], } }, + accessibility: { + options: { + accessibilityLevel: "WCAG2A" + }, + test: { + src: ["build/**/*.html"] + } + }, webpack: { options: { plugins: [ diff --git a/package.json b/package.json index b48bfbfb..13516b7a 100644 --- a/package.json +++ b/package.json @@ -35,6 +35,7 @@ "extract-text-webpack-plugin": "^2.1.0", "file-loader": "^0.10.1", "grunt": ">=0.4.5", + "grunt-accessibility": "~5.0.0", "grunt-chmod": "~1.1.1", "grunt-contrib-clean": "~1.0.0", "grunt-contrib-copy": "~1.0.0",