From 73cbed9cd105d471575033c360be465291a6fee6 Mon Sep 17 00:00:00 2001 From: Ed Sanders Date: Mon, 7 Feb 2022 16:35:42 +0000 Subject: [PATCH] eslint: Lint Gruntile.js using server rules Change-Id: I87efd77d71d8787300539813da04d8679dca764b --- .eslintrc.json | 9 ++------- Gruntfile.js | 5 +++-- modules/.eslintrc.json | 11 +++++++++++ 3 files changed, 16 insertions(+), 9 deletions(-) create mode 100644 modules/.eslintrc.json diff --git a/.eslintrc.json b/.eslintrc.json index 877c66e86..04f9da7ac 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -1,11 +1,6 @@ { "root": true, "extends": [ - "wikimedia/client-es5", - "wikimedia/jquery", - "wikimedia/mediawiki" - ], - "rules": { - "max-len": "off" - } + "wikimedia/server" + ] } diff --git a/Gruntfile.js b/Gruntfile.js index d02711b71..a3e93ea3e 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -1,6 +1,7 @@ -/* eslint-env node, es6 */ +'use strict'; + module.exports = function ( grunt ) { - var conf = grunt.file.readJSON( 'extension.json' ); + const conf = grunt.file.readJSON( 'extension.json' ); grunt.loadNpmTasks( 'grunt-banana-checker' ); grunt.loadNpmTasks( 'grunt-eslint' ); diff --git a/modules/.eslintrc.json b/modules/.eslintrc.json new file mode 100644 index 000000000..877c66e86 --- /dev/null +++ b/modules/.eslintrc.json @@ -0,0 +1,11 @@ +{ + "root": true, + "extends": [ + "wikimedia/client-es5", + "wikimedia/jquery", + "wikimedia/mediawiki" + ], + "rules": { + "max-len": "off" + } +}