]> git.openstreetmap.org Git - rails.git/blobdiff - config/eslint.js
Localisation updates from https://translatewiki.net.
[rails.git] / config / eslint.js
index c968d9e9a568efabe1539ac70af6a5e63901bdd0..6055634aa5a7ef6afab684f4adbb8d988f2a12a6 100644 (file)
@@ -1,5 +1,3 @@
-/* eslint sort-keys: ["error", "asc", {minKeys: 5}] */
-
 const globals = require("globals");
 const js = require("@eslint/js");
 const erb = require("eslint-plugin-erb");
@@ -143,9 +141,11 @@ module.exports = [
       "no-useless-call": "error",
       "no-useless-concat": "error",
       "no-useless-return": "error",
+      "no-var": "error",
       "no-void": "error",
       "no-warning-comments": "warn",
       "operator-assignment": "error",
+      "prefer-const": "error",
       "prefer-object-spread": "error",
       "radix": ["error", "always"],
       "yoda": "error"
@@ -171,6 +171,9 @@ module.exports = [
       globals: {
         ...globals.commonjs
       }
+    },
+    rules: {
+      "sort-keys": ["error", "asc", { minKeys: 5 }]
     }
   }
 ];