@slashnephy/eslint-config 2.0.100 → 2.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/package.json +20 -20
- package/src/base/typescript.js +4 -0
- package/src/base/typescript.ts +5 -0
- package/src/presets/package.json.js +3 -23
- package/src/presets/package.json.ts +3 -23
package/package.json
CHANGED
|
@@ -1,23 +1,24 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@slashnephy/eslint-config",
|
|
3
|
-
"version": "2.
|
|
4
|
-
"
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
"version": "2.1.1",
|
|
4
|
+
"keywords": [
|
|
5
|
+
"eslint",
|
|
6
|
+
"eslintconfig"
|
|
7
|
+
],
|
|
7
8
|
"repository": {
|
|
8
9
|
"type": "git",
|
|
9
10
|
"url": "https://github.com/SlashNephy/eslint-config"
|
|
10
11
|
},
|
|
11
12
|
"license": "MIT",
|
|
13
|
+
"author": "SlashNephy <spica@starry.blue> (https://spica.starry.blue/)",
|
|
14
|
+
"type": "commonjs",
|
|
15
|
+
"main": "./src/index.js",
|
|
12
16
|
"files": [
|
|
13
17
|
"./package.json",
|
|
14
18
|
"./src/**/*.js",
|
|
15
19
|
"./src/**/*.ts",
|
|
16
20
|
"./README.md"
|
|
17
21
|
],
|
|
18
|
-
"publishConfig": {
|
|
19
|
-
"access": "public"
|
|
20
|
-
},
|
|
21
22
|
"scripts": {
|
|
22
23
|
"build": "tsc",
|
|
23
24
|
"bump-version": "ts-node bin/bump-version.ts",
|
|
@@ -30,15 +31,18 @@
|
|
|
30
31
|
"lint:prettier": "prettier --check .",
|
|
31
32
|
"publish": "yarn build && yarn npm publish"
|
|
32
33
|
},
|
|
34
|
+
"eslintConfig": {
|
|
35
|
+
"extends": "./src"
|
|
36
|
+
},
|
|
33
37
|
"dependencies": {
|
|
34
38
|
"@emotion/eslint-plugin": "11.11.0",
|
|
35
|
-
"@next/eslint-plugin-next": "
|
|
39
|
+
"@next/eslint-plugin-next": "14.0.4",
|
|
36
40
|
"@rushstack/eslint-patch": "1.6.1",
|
|
37
41
|
"@susisu/eslint-plugin-safe-typescript": "0.5.2",
|
|
38
42
|
"@typescript-eslint/eslint-plugin": "6.17.0",
|
|
39
43
|
"@typescript-eslint/parser": "6.17.0",
|
|
40
44
|
"eslint-config-airbnb": "19.0.4",
|
|
41
|
-
"eslint-config-next": "
|
|
45
|
+
"eslint-config-next": "14.0.4",
|
|
42
46
|
"eslint-config-prettier": "9.1.0",
|
|
43
47
|
"eslint-config-standard": "17.1.0",
|
|
44
48
|
"eslint-gitignore": "0.1.0",
|
|
@@ -57,7 +61,7 @@
|
|
|
57
61
|
"eslint-plugin-n": "16.6.1",
|
|
58
62
|
"eslint-plugin-no-void-return-type": "1.0.2",
|
|
59
63
|
"eslint-plugin-node": "11.1.0",
|
|
60
|
-
"eslint-plugin-package-json": "0.
|
|
64
|
+
"eslint-plugin-package-json": "0.2.0",
|
|
61
65
|
"eslint-plugin-promise": "6.1.1",
|
|
62
66
|
"eslint-plugin-react": "7.33.2",
|
|
63
67
|
"eslint-plugin-react-hooks": "4.6.0",
|
|
@@ -73,9 +77,6 @@
|
|
|
73
77
|
"typescript": "5.3.3",
|
|
74
78
|
"yaml-eslint-parser": "1.2.2"
|
|
75
79
|
},
|
|
76
|
-
"peerDependencies": {
|
|
77
|
-
"eslint": "^8"
|
|
78
|
-
},
|
|
79
80
|
"devDependencies": {
|
|
80
81
|
"@slashnephy/prettier-config": "1.0.73",
|
|
81
82
|
"@types/eslint": "8.56.0",
|
|
@@ -85,12 +86,11 @@
|
|
|
85
86
|
"prettier": "3.1.1",
|
|
86
87
|
"ts-node": "10.9.2"
|
|
87
88
|
},
|
|
88
|
-
"
|
|
89
|
-
|
|
90
|
-
"extends": "./src"
|
|
89
|
+
"peerDependencies": {
|
|
90
|
+
"eslint": "^8"
|
|
91
91
|
},
|
|
92
|
-
"
|
|
93
|
-
|
|
94
|
-
"
|
|
95
|
-
|
|
92
|
+
"packageManager": "yarn@4.0.2",
|
|
93
|
+
"publishConfig": {
|
|
94
|
+
"access": "public"
|
|
95
|
+
}
|
|
96
96
|
}
|
package/src/base/typescript.js
CHANGED
|
@@ -65,6 +65,10 @@ module.exports = {
|
|
|
65
65
|
format: ['strictCamelCase', 'StrictPascalCase'],
|
|
66
66
|
leadingUnderscore: 'allow',
|
|
67
67
|
},
|
|
68
|
+
{
|
|
69
|
+
selector: ['import'],
|
|
70
|
+
format: ['camelCase', 'PascalCase'],
|
|
71
|
+
},
|
|
68
72
|
{
|
|
69
73
|
selector: ['variable'],
|
|
70
74
|
modifiers: ['const', 'global', 'exported'],
|
package/src/base/typescript.ts
CHANGED
|
@@ -80,6 +80,11 @@ module.exports = {
|
|
|
80
80
|
format: ['strictCamelCase', 'StrictPascalCase'],
|
|
81
81
|
leadingUnderscore: 'allow',
|
|
82
82
|
},
|
|
83
|
+
// インポート名は camelCase / PascalCase
|
|
84
|
+
{
|
|
85
|
+
selector: ['import'],
|
|
86
|
+
format: ['camelCase', 'PascalCase'],
|
|
87
|
+
},
|
|
83
88
|
// export された定数は UPPER_CASE を許容
|
|
84
89
|
{
|
|
85
90
|
selector: ['variable'],
|
|
@@ -9,29 +9,9 @@ module.exports = {
|
|
|
9
9
|
rules: {
|
|
10
10
|
'package-json/order-properties': [
|
|
11
11
|
'error',
|
|
12
|
-
|
|
13
|
-
'
|
|
14
|
-
|
|
15
|
-
'type',
|
|
16
|
-
'main',
|
|
17
|
-
'private',
|
|
18
|
-
'author',
|
|
19
|
-
'description',
|
|
20
|
-
'repository',
|
|
21
|
-
'license',
|
|
22
|
-
'files',
|
|
23
|
-
'exports',
|
|
24
|
-
'publishConfig',
|
|
25
|
-
'scripts',
|
|
26
|
-
'dependencies',
|
|
27
|
-
'peerDependencies',
|
|
28
|
-
'optionalDependencies',
|
|
29
|
-
'bundledDependencies',
|
|
30
|
-
'devDependencies',
|
|
31
|
-
'packageManager',
|
|
32
|
-
'engines',
|
|
33
|
-
'eslintConfig',
|
|
34
|
-
],
|
|
12
|
+
{
|
|
13
|
+
order: 'sort-package-json',
|
|
14
|
+
},
|
|
35
15
|
],
|
|
36
16
|
},
|
|
37
17
|
};
|
|
@@ -9,29 +9,9 @@ module.exports = {
|
|
|
9
9
|
rules: {
|
|
10
10
|
'package-json/order-properties': [
|
|
11
11
|
'error',
|
|
12
|
-
|
|
13
|
-
'
|
|
14
|
-
|
|
15
|
-
'type',
|
|
16
|
-
'main',
|
|
17
|
-
'private',
|
|
18
|
-
'author',
|
|
19
|
-
'description',
|
|
20
|
-
'repository',
|
|
21
|
-
'license',
|
|
22
|
-
'files',
|
|
23
|
-
'exports',
|
|
24
|
-
'publishConfig',
|
|
25
|
-
'scripts',
|
|
26
|
-
'dependencies',
|
|
27
|
-
'peerDependencies',
|
|
28
|
-
'optionalDependencies',
|
|
29
|
-
'bundledDependencies',
|
|
30
|
-
'devDependencies',
|
|
31
|
-
'packageManager',
|
|
32
|
-
'engines',
|
|
33
|
-
'eslintConfig',
|
|
34
|
-
],
|
|
12
|
+
{
|
|
13
|
+
order: 'sort-package-json',
|
|
14
|
+
},
|
|
35
15
|
],
|
|
36
16
|
},
|
|
37
17
|
} satisfies Linter.Config
|