Reactivate eslint-plugin-package-json (#3643)

Somehow the plugin get lost when we moved to ESLint flat config. Now I
reactivated it.

One rules caused sorting the scripts. If this is not okay, I can undo
this and switch off the rule.

Thank's @bugsounet for the pinging in
https://github.com/MagicMirrorOrg/MagicMirror/pull/3637#issuecomment-2509771362.
This commit is contained in:
Kristjan ESPERANTO
2024-12-01 15:26:23 +01:00
committed by GitHub
parent 8d61336e8b
commit 07768c3a88
3 changed files with 27 additions and 23 deletions

View File

@@ -1,12 +1,14 @@
import eslintPluginImport from "eslint-plugin-import";
import eslintPluginJest from "eslint-plugin-jest";
import eslintPluginJs from "@eslint/js";
import eslintPluginPackageJson from "eslint-plugin-package-json/configs/recommended";
import eslintPluginStylistic from "@stylistic/eslint-plugin";
import globals from "globals";
const config = [
eslintPluginJs.configs.recommended,
eslintPluginImport.flatConfigs.recommended,
eslintPluginPackageJson,
{
files: ["**/*.js"],
languageOptions: {
@@ -106,6 +108,7 @@ const config = [
"@stylistic/quote-props": ["error", "as-needed"],
"func-style": "off",
"import/namespace": "off",
"import/no-unresolved": "off",
"max-lines-per-function": ["error", 100],
"no-magic-numbers": "off",
"one-var": "off",