@kasoa/eslint-config 0.0.3 → 0.0.5
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 +1 -1
- package/dist/base/eslint.d.ts.map +1 -1
- package/dist/base/eslint.js +1 -0
- package/dist/base/import-lite.d.ts.map +1 -1
- package/dist/base/typescript-eslint.js +1 -1
- package/dist/base/unused-imports.d.ts.map +1 -1
- package/dist/base/unused-imports.js +4 -13
- package/dist/base/vitest.d.ts.map +1 -1
- package/dist/react/index.js +2 -2
- package/dist/react/jsx-a11y.d.ts +2 -0
- package/dist/react/jsx-a11y.d.ts.map +1 -0
- package/dist/react/jsx-a11y.js +3 -0
- package/package.json +22 -19
- package/src/base/eslint.ts +1 -0
- package/src/base/import-lite.ts +5 -8
- package/src/base/typescript-eslint.ts +1 -1
- package/src/base/unused-imports.ts +4 -13
- package/src/base/vitest.ts +1 -7
- package/src/react/index.ts +2 -2
- package/src/react/jsx-a11y.ts +4 -0
- package/src/react/react-hooks.ts +1 -1
- package/src/react/jsx-a11y-x.ts +0 -13
package/README.md
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eslint.d.ts","sourceRoot":"","sources":["../../src/base/eslint.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,YAAY,
|
|
1
|
+
{"version":3,"file":"eslint.d.ts","sourceRoot":"","sources":["../../src/base/eslint.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,YAAY,kCAMvB,CAAC"}
|
package/dist/base/eslint.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"import-lite.d.ts","sourceRoot":"","sources":["../../src/base/import-lite.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,gBAAgB,
|
|
1
|
+
{"version":3,"file":"import-lite.d.ts","sourceRoot":"","sources":["../../src/base/import-lite.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,gBAAgB,kCAK3B,CAAC"}
|
|
@@ -2,7 +2,7 @@ import { defineConfig } from "eslint/config";
|
|
|
2
2
|
import typescriptEslint from "typescript-eslint";
|
|
3
3
|
export const typescriptEslintConfig = defineConfig(typescriptEslint.configs.strictTypeChecked, typescriptEslint.configs.stylisticTypeChecked, {
|
|
4
4
|
rules: {
|
|
5
|
+
"@typescript-eslint/no-unused-vars": "off",
|
|
5
6
|
"@typescript-eslint/consistent-type-imports": "error",
|
|
6
|
-
"@typescript-eslint/explicit-module-boundary-types": "error",
|
|
7
7
|
},
|
|
8
8
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"unused-imports.d.ts","sourceRoot":"","sources":["../../src/base/unused-imports.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,mBAAmB,
|
|
1
|
+
{"version":3,"file":"unused-imports.d.ts","sourceRoot":"","sources":["../../src/base/unused-imports.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,mBAAmB,kCAQ9B,CAAC"}
|
|
@@ -1,20 +1,11 @@
|
|
|
1
1
|
import unusedImports from "eslint-plugin-unused-imports";
|
|
2
2
|
import { defineConfig } from "eslint/config";
|
|
3
3
|
export const unusedImportsConfig = defineConfig({
|
|
4
|
-
rules: {
|
|
5
|
-
"unused-imports/no-unused-vars": [
|
|
6
|
-
"warn",
|
|
7
|
-
{
|
|
8
|
-
varsIgnorePattern: "^_",
|
|
9
|
-
argsIgnorePattern: "^_",
|
|
10
|
-
args: "after-used",
|
|
11
|
-
vars: "all",
|
|
12
|
-
},
|
|
13
|
-
],
|
|
14
|
-
"unused-imports/no-unused-imports": "error",
|
|
15
|
-
"@typescript-eslint/no-unused-vars": "off",
|
|
16
|
-
},
|
|
17
4
|
plugins: {
|
|
18
5
|
"unused-imports": unusedImports,
|
|
19
6
|
},
|
|
7
|
+
rules: {
|
|
8
|
+
"unused-imports/no-unused-vars": "off",
|
|
9
|
+
"unused-imports/no-unused-imports": "error",
|
|
10
|
+
},
|
|
20
11
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vitest.d.ts","sourceRoot":"","sources":["../../src/base/vitest.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"vitest.d.ts","sourceRoot":"","sources":["../../src/base/vitest.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,YAAY,kCAGvB,CAAC"}
|
package/dist/react/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { defineConfig } from "eslint/config";
|
|
2
2
|
import { base } from "../base/index.js";
|
|
3
3
|
import { eslintReactConfig } from "./eslint-react.js";
|
|
4
|
-
import {
|
|
4
|
+
import { jsxA11yConfig } from "./jsx-a11y.js";
|
|
5
5
|
import { reactCompilerConfig } from "./react-compiler.js";
|
|
6
6
|
import { reactHooksConfig } from "./react-hooks.js";
|
|
7
7
|
import { reactRefreshConfig } from "./react-refresh.js";
|
|
8
8
|
import { reactYouMightNotNeedAnEffectConfig } from "./react-you-might-not-need-an-effect.js";
|
|
9
|
-
export const react = defineConfig(base, eslintReactConfig,
|
|
9
|
+
export const react = defineConfig(base, eslintReactConfig, jsxA11yConfig, reactHooksConfig, reactRefreshConfig, reactCompilerConfig, reactYouMightNotNeedAnEffectConfig);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsx-a11y.d.ts","sourceRoot":"","sources":["../../src/react/jsx-a11y.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,aAAa,kCAA2C,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kasoa/eslint-config",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.5",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"description": "Kasoa's ESLint config",
|
|
@@ -32,46 +32,49 @@
|
|
|
32
32
|
"./node": "./dist/node/index.js",
|
|
33
33
|
"./react": "./dist/react/index.js"
|
|
34
34
|
},
|
|
35
|
+
"publishConfig": {
|
|
36
|
+
"access": "public"
|
|
37
|
+
},
|
|
35
38
|
"dependencies": {
|
|
36
|
-
"@eslint-react/eslint-plugin": "^2.2.
|
|
39
|
+
"@eslint-react/eslint-plugin": "^2.2.4",
|
|
37
40
|
"@eslint/js": "latest",
|
|
38
|
-
"@vitest/eslint-plugin": "^1.
|
|
39
|
-
"eslint": "^9.
|
|
41
|
+
"@vitest/eslint-plugin": "^1.4.0",
|
|
42
|
+
"eslint": "^9.39.0",
|
|
40
43
|
"eslint-config-flat-gitignore": "^2.1.0",
|
|
41
44
|
"eslint-config-prettier": "^10.1.8",
|
|
42
45
|
"eslint-plugin-import-lite": "^0.3.0",
|
|
46
|
+
"eslint-plugin-jsx-a11y": "^6.10.2",
|
|
43
47
|
"eslint-plugin-jsx-a11y-x": "^0.1.1",
|
|
44
48
|
"eslint-plugin-n": "^17.23.1",
|
|
45
49
|
"eslint-plugin-perfectionist": "^4.15.1",
|
|
46
50
|
"eslint-plugin-react-compiler": "19.1.0-rc.2",
|
|
47
|
-
"eslint-plugin-react-hooks": "^7.0.
|
|
51
|
+
"eslint-plugin-react-hooks": "^7.0.1",
|
|
48
52
|
"eslint-plugin-react-refresh": "^0.4.24",
|
|
49
|
-
"eslint-plugin-react-you-might-not-need-an-effect": "^0.
|
|
53
|
+
"eslint-plugin-react-you-might-not-need-an-effect": "^0.7.0",
|
|
50
54
|
"eslint-plugin-unicorn-x": "^3.2.1",
|
|
51
|
-
"eslint-plugin-unused-imports": "^4.
|
|
52
|
-
"globals": "^16.
|
|
53
|
-
"typescript-eslint": "^8.46.
|
|
55
|
+
"eslint-plugin-unused-imports": "^4.3.0",
|
|
56
|
+
"globals": "^16.5.0",
|
|
57
|
+
"typescript-eslint": "^8.46.2"
|
|
54
58
|
},
|
|
55
59
|
"devDependencies": {
|
|
56
|
-
"@types/
|
|
57
|
-
"
|
|
60
|
+
"@types/eslint-plugin-jsx-a11y": "^6.10.1",
|
|
61
|
+
"@types/node": "^24.9.2",
|
|
62
|
+
"@typescript/native-preview": "^7.0.0-dev.20251101.1",
|
|
58
63
|
"prettier": "^3.6.2",
|
|
59
|
-
"typescript": "^5.9.3",
|
|
60
64
|
"@kasoa/tsconfig": "0.0.0"
|
|
61
65
|
},
|
|
62
66
|
"peerDependencies": {
|
|
63
67
|
"eslint": "^9.35.0"
|
|
64
68
|
},
|
|
65
69
|
"engines": {
|
|
66
|
-
"node": ">=
|
|
70
|
+
"node": ">=24"
|
|
67
71
|
},
|
|
68
72
|
"scripts": {
|
|
69
|
-
"dev": "
|
|
70
|
-
"build": "
|
|
71
|
-
"lint": "eslint --fix .",
|
|
72
|
-
"format": "prettier --write .",
|
|
73
|
-
"typecheck": "
|
|
74
|
-
"check:all": "pnpm '/build|typecheck/'",
|
|
73
|
+
"dev": "tsgo --watch",
|
|
74
|
+
"build": "tsgo",
|
|
75
|
+
"lint": "eslint --fix --cache .",
|
|
76
|
+
"format": "prettier --write --cache .",
|
|
77
|
+
"typecheck": "tsgo --noEmit",
|
|
75
78
|
"test": "echo 'No tests'"
|
|
76
79
|
}
|
|
77
80
|
}
|
package/src/base/eslint.ts
CHANGED
package/src/base/import-lite.ts
CHANGED
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
import importLite from "eslint-plugin-import-lite";
|
|
2
2
|
import { defineConfig } from "eslint/config";
|
|
3
3
|
|
|
4
|
-
export const importLiteConfig = defineConfig(
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
"import-lite/consistent-type-specifier-style": ["error", "top-level"],
|
|
9
|
-
"import-lite/newline-after-import": "error",
|
|
10
|
-
},
|
|
4
|
+
export const importLiteConfig = defineConfig(importLite.configs.recommended, {
|
|
5
|
+
rules: {
|
|
6
|
+
"import-lite/consistent-type-specifier-style": ["error", "top-level"],
|
|
7
|
+
"import-lite/newline-after-import": "error",
|
|
11
8
|
},
|
|
12
|
-
);
|
|
9
|
+
});
|
|
@@ -6,8 +6,8 @@ export const typescriptEslintConfig = defineConfig(
|
|
|
6
6
|
typescriptEslint.configs.stylisticTypeChecked,
|
|
7
7
|
{
|
|
8
8
|
rules: {
|
|
9
|
+
"@typescript-eslint/no-unused-vars": "off",
|
|
9
10
|
"@typescript-eslint/consistent-type-imports": "error",
|
|
10
|
-
"@typescript-eslint/explicit-module-boundary-types": "error",
|
|
11
11
|
},
|
|
12
12
|
},
|
|
13
13
|
);
|
|
@@ -2,20 +2,11 @@ import unusedImports from "eslint-plugin-unused-imports";
|
|
|
2
2
|
import { defineConfig } from "eslint/config";
|
|
3
3
|
|
|
4
4
|
export const unusedImportsConfig = defineConfig({
|
|
5
|
-
rules: {
|
|
6
|
-
"unused-imports/no-unused-vars": [
|
|
7
|
-
"warn",
|
|
8
|
-
{
|
|
9
|
-
varsIgnorePattern: "^_",
|
|
10
|
-
argsIgnorePattern: "^_",
|
|
11
|
-
args: "after-used",
|
|
12
|
-
vars: "all",
|
|
13
|
-
},
|
|
14
|
-
],
|
|
15
|
-
"unused-imports/no-unused-imports": "error",
|
|
16
|
-
"@typescript-eslint/no-unused-vars": "off",
|
|
17
|
-
},
|
|
18
5
|
plugins: {
|
|
19
6
|
"unused-imports": unusedImports,
|
|
20
7
|
},
|
|
8
|
+
rules: {
|
|
9
|
+
"unused-imports/no-unused-vars": "off",
|
|
10
|
+
"unused-imports/no-unused-imports": "error",
|
|
11
|
+
},
|
|
21
12
|
});
|
package/src/base/vitest.ts
CHANGED
|
@@ -1,13 +1,7 @@
|
|
|
1
1
|
import vitest from "@vitest/eslint-plugin";
|
|
2
2
|
import { defineConfig } from "eslint/config";
|
|
3
3
|
|
|
4
|
-
interface Vitest {
|
|
5
|
-
configs: {
|
|
6
|
-
recommended: ReturnType<typeof defineConfig>[0];
|
|
7
|
-
};
|
|
8
|
-
}
|
|
9
|
-
|
|
10
4
|
export const vitestConfig = defineConfig({
|
|
11
5
|
files: ["**/tests/**", "**/*.test.ts"],
|
|
12
|
-
...
|
|
6
|
+
...vitest.configs.recommended,
|
|
13
7
|
});
|
package/src/react/index.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineConfig } from "eslint/config";
|
|
2
2
|
import { base } from "../base/index.js";
|
|
3
3
|
import { eslintReactConfig } from "./eslint-react.js";
|
|
4
|
-
import {
|
|
4
|
+
import { jsxA11yConfig } from "./jsx-a11y.js";
|
|
5
5
|
import { reactCompilerConfig } from "./react-compiler.js";
|
|
6
6
|
import { reactHooksConfig } from "./react-hooks.js";
|
|
7
7
|
import { reactRefreshConfig } from "./react-refresh.js";
|
|
@@ -10,7 +10,7 @@ import { reactYouMightNotNeedAnEffectConfig } from "./react-you-might-not-need-a
|
|
|
10
10
|
export const react = defineConfig(
|
|
11
11
|
base,
|
|
12
12
|
eslintReactConfig,
|
|
13
|
-
|
|
13
|
+
jsxA11yConfig,
|
|
14
14
|
reactHooksConfig,
|
|
15
15
|
reactRefreshConfig,
|
|
16
16
|
reactCompilerConfig,
|
package/src/react/react-hooks.ts
CHANGED
package/src/react/jsx-a11y-x.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
// @ts-expect-error - eslint-plugin-jsx-a11y-x is not typed
|
|
2
|
-
import jsxA11yX from "eslint-plugin-jsx-a11y-x";
|
|
3
|
-
import { defineConfig } from "eslint/config";
|
|
4
|
-
|
|
5
|
-
interface JSXA11y {
|
|
6
|
-
flatConfigs: {
|
|
7
|
-
strict: ReturnType<typeof defineConfig>[0];
|
|
8
|
-
};
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export const jsxA11yXConfig = defineConfig(
|
|
12
|
-
(jsxA11yX as JSXA11y).flatConfigs.strict,
|
|
13
|
-
);
|