From 0a323a3d7c261d6e18a9474382a66af1213f2982 Mon Sep 17 00:00:00 2001 From: davikstone Date: Tue, 23 Jan 2024 14:54:25 +0100 Subject: [PATCH] update eslint --- web/saito/lib/glide/.eslintrc.js | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/web/saito/lib/glide/.eslintrc.js b/web/saito/lib/glide/.eslintrc.js index dc28f8ede5..a1a40d9623 100644 --- a/web/saito/lib/glide/.eslintrc.js +++ b/web/saito/lib/glide/.eslintrc.js @@ -6,18 +6,29 @@ module.exports = { jquery: true, }, extends: [ - // 'airbnb-base', "eslint:recommended", "plugin:@typescript-eslint/recommended", + "plugin:import/errors", + "plugin:import/warnings", + "plugin:import/typescript", + "plugin:node/recommended", + "plugin:promise/recommended", "prettier", + "prettier/@typescript-eslint", ], parser: "@typescript-eslint/parser", parserOptions: { - ecmaVersion: 13, + ecmaVersion: 2021, sourceType: "module", }, - plugins: ["@typescript-eslint"], + plugins: ["@typescript-eslint", "import", "node", "promise", "prettier"], rules: { - "prefer-const": 0, + "prefer-const": "warn", + "@typescript-eslint/no-var-requires": "off", + "no-unused-vars": "warn", + "consistent-return": "error", + semi: ["error", "always"], + "prettier/prettier": "error", + // ... more customized rules ... }, };