From 51b1afd2a5a565ae0db485cd436ba1500ad11728 Mon Sep 17 00:00:00 2001 From: Victor Grousset/tuxayo Date: Fri, 11 Oct 2024 04:01:04 +0200 Subject: [PATCH] Bug 38149: Make ESLint config compatible with version 9 Test plan 1. Apply patch 2. Start KTD (to check that stuff is installed automatically) 3. Run this: ESLINT_USE_FLAT_CONFIG='false' eslint koha-tmpl/intranet-tmpl/prog/js/ajax.js 4. You should see errors from prettier in addition to others QA notes: 1. Run this: yarn why eslint; yarn why prettier; yarn why eslint-config-prettier; yarn why eslint-plugin-prettier 2. See that the version are the latest from NPM website 3. See that they are in devDependencies --- .eslintrc.json | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index e6bb78fb4c..e7f78af690 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -5,7 +5,10 @@ }, "extends": [ "eslint:recommended", - "prettier" + "eslint-config-prettier" + ], + "plugins": [ + "eslint-plugin-prettier" ], "rules": { "indent": [ @@ -19,7 +22,9 @@ "semi": [ "error", "always" + ], + "prettier/prettier": [ + "error" ] - }, - "prettier/prettier": "error" + } } -- 2.47.0