mirror of
https://github.com/pa11y/pa11y-dashboard.git
synced 2025-09-24 22:31:15 +00:00
Use the ES6 linting rules from the website (#138)
This commit is contained in:
@@ -15,13 +15,13 @@
|
||||
|
||||
'use strict';
|
||||
|
||||
var standardsArray = require('../../data/standards')();
|
||||
var rules = createStandardDescriptionMap(standardsArray);
|
||||
const standardsArray = require('../../data/standards')();
|
||||
const rules = createStandardDescriptionMap(standardsArray);
|
||||
|
||||
module.exports = presentIgnoreRules;
|
||||
|
||||
function presentIgnoreRules(ignore) {
|
||||
return ignore.map(function(name) {
|
||||
return ignore.map(name => {
|
||||
return {
|
||||
name: name,
|
||||
description: rules[name]
|
||||
@@ -30,9 +30,9 @@ function presentIgnoreRules(ignore) {
|
||||
}
|
||||
|
||||
function createStandardDescriptionMap(standards) {
|
||||
var map = {};
|
||||
standards.forEach(function(standard) {
|
||||
standard.rules.forEach(function(rule) {
|
||||
const map = {};
|
||||
standards.forEach(standard => {
|
||||
standard.rules.forEach(rule => {
|
||||
map[rule.name] = rule.description;
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user