Skip to content

Commit e2a5660

Browse files
committed
Switch to latest hooks plugin and remove markdown plugin
This change upgrades eslint-plugin-react-hooks to v7.0.0 and removes the now unused @eslint/markdown plugin. It also includes minor dependency updates for ESLint and TypeScript peer deps.
1 parent 7d1b6d1 commit e2a5660

File tree

25 files changed

+83
-223
lines changed

25 files changed

+83
-223
lines changed

.pkgs/configs/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"@stylistic/eslint-plugin": "^5.4.0",
2424
"eslint-plugin-de-morgan": "^2.0.0",
2525
"eslint-plugin-function": "^0.0.31",
26-
"eslint-plugin-jsdoc": "^61.0.0",
26+
"eslint-plugin-jsdoc": "^61.0.1",
2727
"eslint-plugin-perfectionist": "^4.15.1",
2828
"eslint-plugin-regexp": "^2.10.0",
2929
"eslint-plugin-unicorn": "^61.0.2",

.pkgs/eslint-plugin-local/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"@typescript-eslint/types": "^8.46.0",
3333
"@typescript-eslint/utils": "^8.46.0",
3434
"eslint-plugin-de-morgan": "^2.0.0",
35-
"eslint-plugin-jsdoc": "^61.0.0",
35+
"eslint-plugin-jsdoc": "^61.0.1",
3636
"eslint-plugin-perfectionist": "^4.15.1",
3737
"eslint-plugin-regexp": "^2.10.0",
3838
"eslint-plugin-unicorn": "^61.0.2",
@@ -46,8 +46,8 @@
4646
"tsdown": "^0.15.6"
4747
},
4848
"peerDependencies": {
49-
"eslint": "^9.36.0",
50-
"typescript": "^5.9.2"
49+
"eslint": "^9.37.0",
50+
"typescript": "^5.9.3"
5151
},
5252
"engines": {
5353
"node": ">=20.19.0"

apps/website/eslint.config.ts

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import react from "@eslint-react/eslint-plugin";
22
import { includeIgnoreFile } from "@eslint/compat";
3-
import markdown from "@eslint/markdown";
43
import { disableTypeChecked, strictTypeChecked } from "@local/configs/eslint";
54
import { recommended as fastImportRecommended } from "eslint-plugin-fast-import";
65
import pluginReactHooks from "eslint-plugin-react-hooks";
@@ -14,8 +13,6 @@ import TSCONFIG from "./tsconfig.json" with { type: "json" };
1413

1514
const GLOB_TS = ["**/*.ts", "**/*.tsx"];
1615
const GLOB_JS = ["**/*.js", "**/*.jsx"];
17-
const GLOB_MD = ["**/*.md"];
18-
const GLOB_MDX = ["**/*.mdx"];
1916
const GLOB_APP = ["app/**/*.{js,ts,jsx,tsx}"];
2017
const GLOB_COMPONENT = ["components/**/*.{js,ts,jsx,tsx}"];
2118
const GLOB_CONFIG = ["**/*.config.{js,mjs,ts,tsx}"];
@@ -31,23 +28,6 @@ const gitignore = fileURLToPath(new URL(".gitignore", import.meta.url));
3128
export default defineConfig([
3229
includeIgnoreFile(gitignore, "Imported .gitignore patterns"),
3330
globalIgnores(GLOB_IGNORES),
34-
{
35-
extends: [
36-
markdown.configs.recommended,
37-
],
38-
files: [...GLOB_MD, ...GLOB_MDX],
39-
language: "markdown/gfm",
40-
rules: {
41-
"markdown/no-html": "warn",
42-
"markdown/no-missing-label-refs": "off",
43-
},
44-
},
45-
{
46-
files: GLOB_MDX,
47-
rules: {
48-
"markdown/no-html": "off",
49-
},
50-
},
5131
{
5232
extends: [
5333
strictTypeChecked,
@@ -65,6 +45,7 @@ export default defineConfig([
6545
extends: [
6646
tseslint.configs.recommendedTypeChecked,
6747
react.configs["recommended-type-checked"],
48+
pluginReactHooks.configs.flat["recommended-latest"] ?? [],
6849
],
6950
files: TSCONFIG.include,
7051
languageOptions: {
@@ -76,11 +57,9 @@ export default defineConfig([
7657
},
7758
},
7859
plugins: {
79-
"react-hooks": pluginReactHooks,
8060
"react-refresh": pluginReactRefresh,
8161
},
8262
rules: {
83-
...pluginReactHooks.configs.recommended.rules,
8463
"@eslint-react/naming-convention/filename": ["error", { rule: "kebab-case" }],
8564
"@eslint-react/no-unused-props": "warn",
8665
"react-refresh/only-export-components": "warn",

apps/website/package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,11 @@
3030
"twoslash": "^0.3.4"
3131
},
3232
"devDependencies": {
33-
"@effect/language-service": "^0.43.2",
33+
"@effect/language-service": "^0.44.0",
3434
"@eslint-react/eslint-plugin": "workspace:*",
3535
"@eslint-react/kit": "workspace:*",
3636
"@eslint-react/shared": "workspace:*",
3737
"@eslint/js": "^9.37.0",
38-
"@eslint/markdown": "^7.4.0",
3938
"@local/configs": "workspace:*",
4039
"@mdx-js/mdx": "^3.1.1",
4140
"@tailwindcss/postcss": "^4.1.14",
@@ -51,7 +50,7 @@
5150
"dedent": "^1.7.0",
5251
"eslint": "^9.37.0",
5352
"eslint-plugin-fast-import": "^1.5.1",
54-
"eslint-plugin-react-hooks": "^6.1.1",
53+
"eslint-plugin-react-hooks": "^7.0.0",
5554
"eslint-plugin-react-refresh": "^0.4.23",
5655
"importx": "^0.5.2",
5756
"postcss": "^8.5.6",

apps/website/services/toaster.ts

Lines changed: 0 additions & 68 deletions
This file was deleted.

eslint.config.ts

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
import { fileURLToPath } from "node:url";
22

33
import { includeIgnoreFile } from "@eslint/compat";
4-
import markdown from "@eslint/markdown";
54
import {
65
GLOB_CONFIGS,
76
GLOB_IGNORES,
8-
GLOB_MD,
97
GLOB_SCRIPTS,
108
GLOB_TESTS,
119
GLOB_TS,
@@ -36,22 +34,6 @@ export default defineConfig([
3634
"examples",
3735
"**/*.d.ts",
3836
]),
39-
{
40-
extends: [
41-
markdown.configs.recommended,
42-
],
43-
files: GLOB_MD,
44-
ignores: [
45-
"**/README.md",
46-
"packages/**/docs/**/*.md",
47-
],
48-
language: "markdown/gfm",
49-
rules: {
50-
"markdown/no-html": "off",
51-
"markdown/no-missing-label-refs": "off",
52-
"markdown/no-multiple-h1": "off",
53-
},
54-
},
5537
{
5638
extends: [
5739
tseslint.configs.strictTypeChecked,

examples/next/eslint.config.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,13 +44,12 @@ export default defineConfig([
4444
extends: [
4545
eslintReact.configs["recommended-type-checked"],
4646
eslintPluginReactRefresh.configs.recommended,
47+
eslintPluginReactHooks.configs.flat["recommended-latest"] ?? [],
4748
],
4849
plugins: {
49-
"react-hooks": eslintPluginReactHooks,
5050
"@next/next": eslintPluginNext,
5151
},
5252
rules: {
53-
...eslintPluginReactHooks.configs.recommended.rules,
5453
...eslintPluginNext.configs.recommended.rules,
5554
...eslintPluginNext.configs["core-web-vitals"].rules,
5655
},

examples/next/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"@types/react": "^19.2.2",
2828
"@types/react-dom": "^19.2.1",
2929
"eslint": "^9.37.0",
30-
"eslint-plugin-react-hooks": "^6.1.1",
30+
"eslint-plugin-react-hooks": "^7.0.0",
3131
"eslint-plugin-react-refresh": "^0.4.23",
3232
"typescript": "^5.9.3",
3333
"typescript-eslint": "^8.46.0"

examples/react-dom-js/eslint.config.js

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,8 @@ export default defineConfig([
5252
files: JSCONFIG_APP.include,
5353
extends: [
5454
eslintReact.configs.recommended,
55+
eslintPluginReactHooks.configs.flat["recommended-latest"] ?? [],
5556
eslintPluginReactRefresh.configs.recommended,
5657
],
57-
plugins: {
58-
"react-hooks": eslintPluginReactHooks,
59-
},
60-
rules: {
61-
...eslintPluginReactHooks.configs.recommended.rules,
62-
},
6358
},
6459
]);

examples/react-dom-js/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
"@types/react-dom": "^19.2.1",
2323
"@vitejs/plugin-react": "^5.0.4",
2424
"eslint": "^9.37.0",
25-
"eslint-plugin-react-hooks": "^6.1.1",
25+
"eslint-plugin-react-hooks": "^7.0.0",
2626
"eslint-plugin-react-refresh": "^0.4.23",
2727
"globals": "^16.4.0",
2828
"vite": "^7.1.9"

0 commit comments

Comments
 (0)