eslint-config-matsuri 4.4.0 → 5.0.0
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/README.md +2 -10
- package/configs/base.js +1 -1
- package/configs/javascript.js +1 -1
- package/configs/react.js +1 -1
- package/configs/test.js +1 -1
- package/configs/typescript.js +2 -5
- package/index.d.ts +6 -6
- package/index.js +1 -1
- package/package.json +11 -9
package/README.md
CHANGED
|
@@ -25,7 +25,7 @@ Flat configをv3からサポートしています。eslint.config.jsに次のよ
|
|
|
25
25
|
```js
|
|
26
26
|
import config from "eslint-config-matsuri";
|
|
27
27
|
|
|
28
|
-
/** @type { import("eslint").Linter.
|
|
28
|
+
/** @type { import("eslint").Linter.Config[] } */
|
|
29
29
|
export default config
|
|
30
30
|
```
|
|
31
31
|
|
|
@@ -34,7 +34,7 @@ export default config
|
|
|
34
34
|
```js
|
|
35
35
|
import { configs } from "eslint-config-matsuri";
|
|
36
36
|
|
|
37
|
-
/** @type { import("eslint").Linter.
|
|
37
|
+
/** @type { import("eslint").Linter.Config[] } */
|
|
38
38
|
export default [
|
|
39
39
|
configs.base,
|
|
40
40
|
{
|
|
@@ -70,14 +70,6 @@ export default [
|
|
|
70
70
|
]
|
|
71
71
|
```
|
|
72
72
|
|
|
73
|
-
VSCodeでFlag configを利用する場合は、`.vscode/settings.json`に次の設定を追加する必要があります。
|
|
74
|
-
|
|
75
|
-
```json
|
|
76
|
-
{
|
|
77
|
-
"eslint.experimental.useFlatConfig": true
|
|
78
|
-
}
|
|
79
|
-
```
|
|
80
|
-
|
|
81
73
|
|
|
82
74
|
## Contributing
|
|
83
75
|
|
package/configs/base.js
CHANGED
package/configs/javascript.js
CHANGED
|
@@ -4,7 +4,7 @@ import pluginPrettier from "eslint-config-prettier";
|
|
|
4
4
|
import pluginSortImports from "eslint-plugin-sort-imports-es6-autofix";
|
|
5
5
|
import pluginUnusedImport from "eslint-plugin-unused-imports";
|
|
6
6
|
|
|
7
|
-
/** @type {import("eslint").Linter.
|
|
7
|
+
/** @type {import("eslint").Linter.Config } */
|
|
8
8
|
export const jsConfig = {
|
|
9
9
|
linterOptions: {
|
|
10
10
|
reportUnusedDisableDirectives: true,
|
package/configs/react.js
CHANGED
|
@@ -4,7 +4,7 @@ import pluginJsxA11y from "eslint-plugin-jsx-a11y";
|
|
|
4
4
|
import pluginReact from "eslint-plugin-react";
|
|
5
5
|
import pluginReactHooks from "eslint-plugin-react-hooks";
|
|
6
6
|
|
|
7
|
-
/** @type {import("eslint").Linter.
|
|
7
|
+
/** @type {import("eslint").Linter.Config } */
|
|
8
8
|
export const reactConfig = {
|
|
9
9
|
files: ["**/*.tsx"],
|
|
10
10
|
languageOptions: {
|
package/configs/test.js
CHANGED
package/configs/typescript.js
CHANGED
|
@@ -19,7 +19,7 @@ const tseslintStylisticTypeCheckedRules = getRulesFromConfigArray(
|
|
|
19
19
|
tseslint.configs.stylisticTypeChecked
|
|
20
20
|
);
|
|
21
21
|
|
|
22
|
-
/** @type {import("eslint").Linter.
|
|
22
|
+
/** @type {import("eslint").Linter.Config } */
|
|
23
23
|
export const tsConfig = {
|
|
24
24
|
files: ["**/*.ts", "**/*.tsx"],
|
|
25
25
|
plugins: {
|
|
@@ -37,8 +37,6 @@ export const tsConfig = {
|
|
|
37
37
|
"@typescript-eslint/no-unused-vars": "off",
|
|
38
38
|
"@typescript-eslint/explicit-module-boundary-types": "off",
|
|
39
39
|
|
|
40
|
-
"@typescript-eslint/no-empty-interface": "off",
|
|
41
|
-
|
|
42
40
|
"@typescript-eslint/no-non-null-assertion": "error",
|
|
43
41
|
|
|
44
42
|
"@typescript-eslint/consistent-type-exports": "error",
|
|
@@ -53,7 +51,7 @@ export const tsConfig = {
|
|
|
53
51
|
allowAny: true,
|
|
54
52
|
},
|
|
55
53
|
],
|
|
56
|
-
"@typescript-eslint/
|
|
54
|
+
"@typescript-eslint/no-restricted-types": [
|
|
57
55
|
"error",
|
|
58
56
|
{
|
|
59
57
|
types: {
|
|
@@ -76,7 +74,6 @@ export const tsConfig = {
|
|
|
76
74
|
},
|
|
77
75
|
},
|
|
78
76
|
],
|
|
79
|
-
|
|
80
77
|
/**
|
|
81
78
|
* Allow `() => Promise<void>` in JSX event handler.
|
|
82
79
|
* @see https://github.com/typescript-eslint/typescript-eslint/blob/f373fac1dd0150273d98cee5bed606bbd3f55e4b/packages/eslint-plugin/docs/rules/no-misused-promises.md#checksvoidreturn
|
package/index.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { Linter } from "eslint";
|
|
2
2
|
|
|
3
3
|
export declare const configs: {
|
|
4
|
-
base: Linter.
|
|
5
|
-
javascript: Linter.
|
|
6
|
-
typescript: Linter.
|
|
7
|
-
react: Linter.
|
|
8
|
-
test: Linter.
|
|
4
|
+
base: Linter.Config;
|
|
5
|
+
javascript: Linter.Config;
|
|
6
|
+
typescript: Linter.Config;
|
|
7
|
+
react: Linter.Config;
|
|
8
|
+
test: Linter.Config;
|
|
9
9
|
};
|
|
10
10
|
|
|
11
|
-
declare const config: Linter.
|
|
11
|
+
declare const config: Linter.Config[];
|
|
12
12
|
|
|
13
13
|
export default config;
|
package/index.js
CHANGED
|
@@ -12,7 +12,7 @@ export const configs = {
|
|
|
12
12
|
test: testConfig,
|
|
13
13
|
};
|
|
14
14
|
|
|
15
|
-
/** @type { import("eslint").Linter.
|
|
15
|
+
/** @type { import("eslint").Linter.Config[] } */
|
|
16
16
|
const config = [baseConfig, jsConfig, tsConfig, reactConfig, testConfig];
|
|
17
17
|
|
|
18
18
|
export default config;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eslint-config-matsuri",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "",
|
|
6
6
|
"main": "index.js",
|
|
@@ -14,7 +14,9 @@
|
|
|
14
14
|
"configs"
|
|
15
15
|
],
|
|
16
16
|
"scripts": {
|
|
17
|
-
"test": "eslint . --max-warnings 0"
|
|
17
|
+
"test": "eslint . --max-warnings 0",
|
|
18
|
+
"inspect": "npx @eslint/config-inspector",
|
|
19
|
+
"build-inspect": "npx @eslint/config-inspector build --base /eslint-config-matsuri/"
|
|
18
20
|
},
|
|
19
21
|
"keywords": [],
|
|
20
22
|
"author": "hrdtbs",
|
|
@@ -22,18 +24,18 @@
|
|
|
22
24
|
"registry": "https://registry.npmjs.org/"
|
|
23
25
|
},
|
|
24
26
|
"peerDependencies": {
|
|
25
|
-
"eslint": "^8.43.0"
|
|
27
|
+
"eslint": "^8.43.0 || ^9.0.0"
|
|
26
28
|
},
|
|
27
29
|
"dependencies": {
|
|
28
|
-
"@eslint/js": "9.
|
|
30
|
+
"@eslint/js": "9.9.0",
|
|
29
31
|
"eslint-config-prettier": "9.1.0",
|
|
30
32
|
"eslint-plugin-css-reorder": "0.5.1",
|
|
31
|
-
"eslint-plugin-jsx-a11y": "6.
|
|
32
|
-
"eslint-plugin-react": "7.
|
|
33
|
+
"eslint-plugin-jsx-a11y": "6.9.0",
|
|
34
|
+
"eslint-plugin-react": "7.35.0",
|
|
33
35
|
"eslint-plugin-react-hooks": "4.6.2",
|
|
34
36
|
"eslint-plugin-sort-imports-es6-autofix": "0.6.0",
|
|
35
|
-
"eslint-plugin-unused-imports": "
|
|
36
|
-
"globals": "15.
|
|
37
|
-
"typescript-eslint": "
|
|
37
|
+
"eslint-plugin-unused-imports": "4.1.3",
|
|
38
|
+
"globals": "15.9.0",
|
|
39
|
+
"typescript-eslint": "8.0.1"
|
|
38
40
|
}
|
|
39
41
|
}
|