@newhighsco/eslint-config 5.0.1 → 5.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/eslint.config.js +9 -8
- package/package.json +2 -2
package/eslint.config.js
CHANGED
|
@@ -3,7 +3,9 @@ import { join } from 'node:path'
|
|
|
3
3
|
|
|
4
4
|
import { includeIgnoreFile } from '@eslint/compat'
|
|
5
5
|
import { FlatCompat } from '@eslint/eslintrc'
|
|
6
|
+
import json from '@eslint/json'
|
|
6
7
|
import { defineConfig } from 'eslint/config'
|
|
8
|
+
import prettierRecommended from 'eslint-plugin-prettier/recommended'
|
|
7
9
|
|
|
8
10
|
const gitignore = join(process.cwd(), '.gitignore')
|
|
9
11
|
const compat = new FlatCompat()
|
|
@@ -17,7 +19,6 @@ export default defineConfig(
|
|
|
17
19
|
...compat.config({
|
|
18
20
|
parserOptions: { requireConfigFile: false },
|
|
19
21
|
env: { jest: true },
|
|
20
|
-
extends: ['standard', 'plugin:prettier/recommended'],
|
|
21
22
|
ignorePatterns: ['!.github', '!.storybook'],
|
|
22
23
|
plugins: ['simple-import-sort'],
|
|
23
24
|
rules: {
|
|
@@ -25,13 +26,10 @@ export default defineConfig(
|
|
|
25
26
|
'simple-import-sort/exports': 'error'
|
|
26
27
|
},
|
|
27
28
|
overrides: [
|
|
28
|
-
//
|
|
29
|
+
// Javascript
|
|
29
30
|
{
|
|
30
|
-
files: ['
|
|
31
|
-
extends: [
|
|
32
|
-
'plugin:json/recommended-legacy',
|
|
33
|
-
'plugin:prettier/recommended'
|
|
34
|
-
]
|
|
31
|
+
files: ['*.?(c|m)js'],
|
|
32
|
+
extends: ['standard', 'plugin:prettier/recommended']
|
|
35
33
|
},
|
|
36
34
|
// Typescript
|
|
37
35
|
typescript && {
|
|
@@ -91,8 +89,11 @@ export default defineConfig(
|
|
|
91
89
|
},
|
|
92
90
|
// Cypress
|
|
93
91
|
{ files: ['*.cy.*'], extends: ['plugin:cypress/recommended'] }
|
|
94
|
-
]
|
|
92
|
+
].filter(Boolean)
|
|
95
93
|
}),
|
|
94
|
+
// JSON
|
|
95
|
+
{ files: ['**/*.json'], plugins: { json }, language: 'json/json' },
|
|
96
|
+
{ files: ['**/*.json'], ...prettierRecommended },
|
|
96
97
|
ignore && includeIgnoreFile(gitignore)
|
|
97
98
|
].filter(Boolean)
|
|
98
99
|
)
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@newhighsco/eslint-config",
|
|
3
3
|
"description": "New High Score shareable config for ESLint",
|
|
4
|
-
"version": "5.
|
|
4
|
+
"version": "5.1.1",
|
|
5
5
|
"author": "New High Score",
|
|
6
6
|
"license": "ISC",
|
|
7
7
|
"private": false,
|
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
"files": [],
|
|
23
23
|
"dependencies": {
|
|
24
24
|
"@eslint/compat": "1.4.0",
|
|
25
|
+
"@eslint/json": "0.13.2",
|
|
25
26
|
"@eslint/eslintrc": "3.3.1",
|
|
26
27
|
"@typescript-eslint/eslint-plugin": "7.18.0",
|
|
27
28
|
"@typescript-eslint/parser": "7.18.0",
|
|
@@ -33,7 +34,6 @@
|
|
|
33
34
|
"eslint-formatter-junit": "8.40.0",
|
|
34
35
|
"eslint-plugin-cypress": "3.6.0",
|
|
35
36
|
"eslint-plugin-import": "2.32.0",
|
|
36
|
-
"eslint-plugin-json": "4.0.1",
|
|
37
37
|
"eslint-plugin-jsx-a11y": "6.10.2",
|
|
38
38
|
"eslint-plugin-mdx": "3.6.2",
|
|
39
39
|
"eslint-plugin-n": "17.15.1",
|