@w0s/eslint-config 7.3.1 → 8.0.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/README.md CHANGED
@@ -1,7 +1,7 @@
1
1
  # eslint-config
2
2
 
3
3
  [![npm version](https://badge.fury.io/js/%40w0s%2Feslint-config.svg)](https://www.npmjs.com/package/@w0s/eslint-config)
4
- [![test status](https://github.com/SaekiTominaga/w0s/actions/workflows/eslint-test.yml/badge.svg)](https://github.com/SaekiTominaga/w0s/actions/workflows/eslint-test.yml)
4
+ [![Workflow status](https://github.com/SaekiTominaga/w0s/actions/workflows/eslint.yml/badge.svg)](https://github.com/SaekiTominaga/w0s/actions/workflows/eslint.yml)
5
5
 
6
6
  ESLint configuration file used on my personal website ([`w0s.jp`](https://github.com/SaekiTominaga/w0s.jp)).
7
7
 
@@ -22,7 +22,7 @@ ESLint configuration file used on my personal website ([`w0s.jp`](https://github
22
22
  ```javascript
23
23
  import w0sConfig from '@w0s/eslint-config';
24
24
 
25
- /** @type {import("eslint").Linter.FlatConfig[]} */
25
+ /** @type {import("eslint").Linter.Config[]} */
26
26
  export default [
27
27
  ...w0sConfig,
28
28
  {
package/eslint.config.js CHANGED
@@ -1,6 +1,4 @@
1
- // @ts-check
2
-
3
- // @ts-expect-error: ts(1192)
1
+ // @ts-expect-error: ts(7016)
4
2
  import pluginImport from 'eslint-plugin-import';
5
3
  import pluginJsdoc from 'eslint-plugin-jsdoc';
6
4
  import globals from 'globals';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@w0s/eslint-config",
3
- "version": "7.3.1",
3
+ "version": "8.0.1",
4
4
  "description": "ESLint configuration file used on `w0s.jp`",
5
5
  "keywords": [
6
6
  "eslint",
@@ -21,22 +21,23 @@
21
21
  },
22
22
  "scripts": {
23
23
  "test": "node __tests__/index.test.js",
24
- "lint": "eslint __tests__/*.js rules/**/*.js eslint.config.js"
24
+ "prelint": "tsc",
25
+ "lint": "eslint __tests__/valid/**/*.{js,ts} __tests__/*.test.js rules/**/*.js eslint.config.js"
25
26
  },
26
27
  "dependencies": {
27
- "@eslint/js": "^8.57.0",
28
- "eslint-plugin-import": "^2.30.0",
29
- "eslint-plugin-jsdoc": "^50.2.2",
30
- "globals": "^15.9.0",
31
- "typescript-eslint": "^8.5.0"
28
+ "@eslint/js": "^9.12.0",
29
+ "eslint-plugin-import": "^2.31.0",
30
+ "eslint-plugin-jsdoc": "^50.3.1",
31
+ "globals": "^15.10.0",
32
+ "typescript-eslint": "^8.8.0"
32
33
  },
33
34
  "devDependencies": {
34
- "@types/eslint": "^8.56.11",
35
- "@types/node": "^22.5.4",
36
- "eslint": "^8.57.0"
35
+ "@types/eslint__js": "^8.42.3",
36
+ "@types/node": "^22.7.4",
37
+ "eslint": "^9.12.0"
37
38
  },
38
39
  "peerDependencies": {
39
- "eslint": "^8.57.0"
40
+ "eslint": "^9.12.0"
40
41
  },
41
42
  "publishConfig": {
42
43
  "access": "public"
@@ -1,6 +1,4 @@
1
- // @ts-check
2
-
3
- /** @type {import("eslint").Linter.FlatConfig} */
1
+ /** @type {import("eslint").Linter.Config} */
4
2
  export default {
5
3
  rules: {
6
4
  'line-comment-position': [
@@ -1,6 +1,4 @@
1
- // @ts-check
2
-
3
- /** @type {import("eslint").Linter.FlatConfig} */
1
+ /** @type {import("eslint").Linter.Config} */
4
2
  export default {
5
3
  rules: {
6
4
  'array-callback-return': [
@@ -1,6 +1,4 @@
1
- // @ts-check
2
-
3
- /** @type {import("eslint").Linter.FlatConfig} */
1
+ /** @type {import("eslint").Linter.Config} */
4
2
  export default {
5
3
  rules: {
6
4
  'arrow-body-style': 'error', // eslint-config-airbnb-base@15.0.0; es6
package/rules/import.js CHANGED
@@ -1,14 +1,13 @@
1
- // @ts-check
2
1
  /* eslint-disable jsdoc/lines-before-block */
3
2
 
4
- /** @type {import("eslint").Linter.FlatConfig} */
3
+ /** @type {import("eslint").Linter.Config} */
5
4
  export default {
6
5
  rules: {
7
6
  /**
8
7
  * Helpful warnings
9
8
  */
10
9
  /* ✅ import/export */
11
- /* import/no-deprecated TODO: parserPath or languageOptions.parser is required! */
10
+ 'import/no-deprecated': 'error',
12
11
  'import/no-empty-named-blocks': 'error',
13
12
  'import/no-extraneous-dependencies': [
14
13
  'error',
@@ -20,8 +19,8 @@ export default {
20
19
  },
21
20
  ],
22
21
  'import/no-mutable-exports': 'error',
23
- 'import/no-named-as-default': 'off', // ✅ TODO: parserPath or languageOptions.parser is required! / 有効にする際は *.test.js での無効化を検討
24
- 'import/no-named-as-default-member': 'off', // ✅ TODO: parserPath or languageOptions.parser is required! / 有効にする際は *.test.js での無効化を検討
22
+ /* ✅ import/no-named-as-default */
23
+ /* ✅ import/no-named-as-default-member */
25
24
  /* import/no-unused-modules */
26
25
 
27
26
  /**
@@ -36,9 +35,9 @@ export default {
36
35
  /**
37
36
  * Static analysis
38
37
  */
39
- 'import/default': 'off', // ✅ TODO: parserPath or languageOptions.parser is required!
38
+ /* ✅ import/default */
40
39
  /* ✅ import/named */
41
- 'import/namespace': 'off', // ✅ TODO: parserPath or languageOptions.parser is required!
40
+ /* ✅ import/namespace */
42
41
  'import/no-absolute-path': 'error',
43
42
  /* import/no-cycle ⚠ This rule is comparatively computationally expensive */
44
43
  /* import/no-dynamic-require */
package/rules/jsdoc.js CHANGED
@@ -1,6 +1,4 @@
1
- // @ts-check
2
-
3
- /** @type {import("eslint").Linter.FlatConfig} */
1
+ /** @type {import("eslint").Linter.Config} */
4
2
  export default {
5
3
  rules: {
6
4
  'jsdoc/lines-before-block': 'warn',