ESLint config for CommonJS module syntax

Changes the eslint rules to support "require", "module.exports", and
relaxes the top-level lexical scope for each file.

FIXME: This allows a combination of CommonJS code, which becomes
unsafe global code scope if used in a "scripts" module.  What's the
correct order of migration steps?

Change-Id: I2f80732942a602c0fcff5c0dad1e2afc2640651e
This commit is contained in:
Adam Wight 2020-03-29 21:28:15 +02:00
parent c685ea38f7
commit 156427df55

View file

@ -1,5 +1,8 @@
{
"root": true,
"env": {
"commonjs": true
},
"extends": [
"wikimedia/client",
"wikimedia/jquery",