@ghettoddos/eslint-config 1.0.3 → 1.1.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.
Files changed (3) hide show
  1. package/dist/index.d.ts +331 -277
  2. package/dist/index.js +61 -50
  3. package/package.json +21 -14
package/dist/index.js CHANGED
@@ -1012,22 +1012,73 @@ async function react(options = {}) {
1012
1012
  },
1013
1013
  name: "react/rules",
1014
1014
  rules: {
1015
- // recommended rules from @eslint-react/dom
1016
- "react-dom/no-children-in-void-dom-elements": "warn",
1015
+ // recommended rules from eslint-plugin-react-x https://eslint-react.xyz/docs/rules/overview#core-rules
1016
+ "react/no-access-state-in-setstate": "error",
1017
+ "react/no-array-index-key": "warn",
1018
+ "react/no-children-count": "warn",
1019
+ "react/no-children-for-each": "warn",
1020
+ "react/no-children-map": "warn",
1021
+ "react/no-children-only": "warn",
1022
+ "react/no-children-to-array": "warn",
1023
+ "react/no-clone-element": "warn",
1024
+ "react/no-comment-textnodes": "warn",
1025
+ "react/no-component-will-mount": "error",
1026
+ "react/no-component-will-receive-props": "error",
1027
+ "react/no-component-will-update": "error",
1028
+ "react/no-context-provider": "warn",
1029
+ "react/no-create-ref": "error",
1030
+ "react/no-default-props": "error",
1031
+ "react/no-direct-mutation-state": "error",
1032
+ "react/no-duplicate-jsx-props": "warn",
1033
+ "react/no-duplicate-key": "warn",
1034
+ "react/no-forward-ref": "warn",
1035
+ "react/no-implicit-key": "warn",
1036
+ "react/no-missing-key": "error",
1037
+ "react/no-nested-component-definitions": "error",
1038
+ "react/no-prop-types": "error",
1039
+ "react/no-redundant-should-component-update": "error",
1040
+ "react/no-set-state-in-component-did-mount": "warn",
1041
+ "react/no-set-state-in-component-did-update": "warn",
1042
+ "react/no-set-state-in-component-will-update": "warn",
1043
+ "react/no-string-refs": "error",
1044
+ "react/no-unsafe-component-will-mount": "warn",
1045
+ "react/no-unsafe-component-will-receive-props": "warn",
1046
+ "react/no-unsafe-component-will-update": "warn",
1047
+ "react/no-unstable-context-value": "warn",
1048
+ "react/no-unstable-default-props": "warn",
1049
+ "react/no-unused-class-component-members": "warn",
1050
+ "react/no-unused-state": "warn",
1051
+ "react/no-use-context": "warn",
1052
+ "react/no-useless-forward-ref": "warn",
1053
+ "react/use-jsx-vars": "warn",
1054
+ // recommended rules from eslint-plugin-react-dom https://eslint-react.xyz/docs/rules/overview#dom-rules
1017
1055
  "react-dom/no-dangerously-set-innerhtml": "warn",
1018
1056
  "react-dom/no-dangerously-set-innerhtml-with-children": "error",
1019
1057
  "react-dom/no-find-dom-node": "error",
1058
+ "react-dom/no-flush-sync": "error",
1059
+ "react-dom/no-hydrate": "error",
1020
1060
  "react-dom/no-missing-button-type": "warn",
1021
1061
  "react-dom/no-missing-iframe-sandbox": "warn",
1022
1062
  "react-dom/no-namespace": "error",
1063
+ "react-dom/no-render": "error",
1023
1064
  "react-dom/no-render-return-value": "error",
1024
1065
  "react-dom/no-script-url": "warn",
1025
1066
  "react-dom/no-unsafe-iframe-sandbox": "warn",
1026
1067
  "react-dom/no-unsafe-target-blank": "warn",
1027
- // recommended rules react-hooks
1068
+ "react-dom/no-use-form-state": "error",
1069
+ "react-dom/no-void-elements-with-children": "error",
1070
+ // recommended rules eslint-plugin-react-hooks https://github.com/facebook/react/tree/main/packages/eslint-plugin-react-hooks/src/rules
1028
1071
  "react-hooks/exhaustive-deps": "warn",
1029
1072
  "react-hooks/rules-of-hooks": "error",
1030
- // react refresh
1073
+ // recommended rules from eslint-plugin-react-hooks-extra https://eslint-react.xyz/docs/rules/overview#hooks-extra-rules
1074
+ "react-hooks-extra/no-direct-set-state-in-use-effect": "warn",
1075
+ "react-hooks-extra/no-unnecessary-use-prefix": "warn",
1076
+ // recommended rules from eslint-plugin-react-web-api https://eslint-react.xyz/docs/rules/overview#web-api-rules
1077
+ "react-web-api/no-leaked-event-listener": "warn",
1078
+ "react-web-api/no-leaked-interval": "warn",
1079
+ "react-web-api/no-leaked-resize-observer": "warn",
1080
+ "react-web-api/no-leaked-timeout": "warn",
1081
+ // preconfigured rules from eslint-plugin-react-refresh https://github.com/ArnaudBarre/eslint-plugin-react-refresh/tree/main/src
1031
1082
  "react-refresh/only-export-components": [
1032
1083
  "warn",
1033
1084
  {
@@ -1052,52 +1103,6 @@ async function react(options = {}) {
1052
1103
  ]
1053
1104
  }
1054
1105
  ],
1055
- // recommended rules from @eslint-react/web-api
1056
- "react-web-api/no-leaked-event-listener": "warn",
1057
- "react-web-api/no-leaked-interval": "warn",
1058
- "react-web-api/no-leaked-resize-observer": "warn",
1059
- "react-web-api/no-leaked-timeout": "warn",
1060
- // recommended rules from @eslint-react
1061
- "react/ensure-forward-ref-using-ref": "warn",
1062
- "react/jsx-no-duplicate-props": "warn",
1063
- "react/jsx-uses-vars": "warn",
1064
- "react/no-access-state-in-setstate": "error",
1065
- "react/no-array-index-key": "warn",
1066
- "react/no-children-count": "warn",
1067
- "react/no-children-for-each": "warn",
1068
- "react/no-children-map": "warn",
1069
- "react/no-children-only": "warn",
1070
- "react/no-children-to-array": "warn",
1071
- "react/no-clone-element": "warn",
1072
- "react/no-comment-textnodes": "warn",
1073
- "react/no-component-will-mount": "error",
1074
- "react/no-component-will-receive-props": "error",
1075
- "react/no-component-will-update": "error",
1076
- "react/no-context-provider": "warn",
1077
- "react/no-create-ref": "error",
1078
- "react/no-default-props": "error",
1079
- "react/no-direct-mutation-state": "error",
1080
- "react/no-duplicate-key": "error",
1081
- "react/no-forward-ref": "warn",
1082
- "react/no-implicit-key": "warn",
1083
- "react/no-missing-key": "error",
1084
- "react/no-nested-components": "error",
1085
- "react/no-prop-types": "error",
1086
- "react/no-redundant-should-component-update": "error",
1087
- "react/no-set-state-in-component-did-mount": "warn",
1088
- "react/no-set-state-in-component-did-update": "warn",
1089
- "react/no-set-state-in-component-will-update": "warn",
1090
- "react/no-string-refs": "error",
1091
- "react/no-unsafe-component-will-mount": "warn",
1092
- "react/no-unsafe-component-will-receive-props": "warn",
1093
- "react/no-unsafe-component-will-update": "warn",
1094
- "react/no-unstable-context-value": "warn",
1095
- "react/no-unstable-default-props": "warn",
1096
- "react/no-unused-class-component-members": "warn",
1097
- "react/no-unused-state": "warn",
1098
- "react/prefer-destructuring-assignment": "warn",
1099
- "react/prefer-shorthand-boolean": "warn",
1100
- "react/prefer-shorthand-fragment": "warn",
1101
1106
  // overrides
1102
1107
  ...overrides
1103
1108
  }
@@ -1280,6 +1285,7 @@ function sortTsconfig() {
1280
1285
  "useDefineForClassFields",
1281
1286
  "emitDecoratorMetadata",
1282
1287
  "experimentalDecorators",
1288
+ "libReplacement",
1283
1289
  /* Modules */
1284
1290
  "baseUrl",
1285
1291
  "rootDir",
@@ -1354,6 +1360,7 @@ function sortTsconfig() {
1354
1360
  "isolatedModules",
1355
1361
  "preserveSymlinks",
1356
1362
  "verbatimModuleSyntax",
1363
+ "erasableSyntaxOnly",
1357
1364
  /* Completeness */
1358
1365
  "skipDefaultLibCheck",
1359
1366
  "skipLibCheck"
@@ -1721,6 +1728,10 @@ async function yaml(options = {}) {
1721
1728
  "supportedArchitectures"
1722
1729
  ],
1723
1730
  pathPattern: "^$"
1731
+ },
1732
+ {
1733
+ order: { type: "asc" },
1734
+ pathPattern: ".*"
1724
1735
  }
1725
1736
  ]
1726
1737
  }
package/package.json CHANGED
@@ -1,11 +1,18 @@
1
1
  {
2
2
  "name": "@ghettoddos/eslint-config",
3
3
  "type": "module",
4
- "version": "1.0.3",
4
+ "version": "1.1.0",
5
5
  "description": "ghettoDdOS ESLint config",
6
6
  "author": "ghettoDdOS <pen.egor2002@gamil.com> (https://github.com/ghettoDdOS/)",
7
7
  "license": "MIT",
8
8
  "homepage": "https://github.com/ghettoDdOS/eslint-config",
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "git+https://github.com/ghettoDdOS/eslint-config.git"
12
+ },
13
+ "bugs": {
14
+ "url": "https://github.com/ghettoDdOS/eslint-config/issues"
15
+ },
9
16
  "keywords": [
10
17
  "eslint-config"
11
18
  ],
@@ -38,24 +45,24 @@
38
45
  "@antfu/install-pkg": "^1.0.0",
39
46
  "@clack/prompts": "^0.10.0",
40
47
  "@eslint-community/eslint-plugin-eslint-comments": "^4.4.1",
41
- "@eslint-react/eslint-plugin": "^1.31.0",
48
+ "@eslint-react/eslint-plugin": "^1.38.3",
42
49
  "@eslint/markdown": "^6.3.0",
43
50
  "@stylistic/eslint-plugin": "^4.2.0",
44
- "@typescript-eslint/eslint-plugin": "^8.26.0",
45
- "@typescript-eslint/parser": "^8.26.0",
51
+ "@typescript-eslint/eslint-plugin": "^8.28.0",
52
+ "@typescript-eslint/parser": "^8.28.0",
46
53
  "eslint-config-flat-gitignore": "^2.1.0",
47
54
  "eslint-flat-config-utils": "^2.0.1",
48
55
  "eslint-merge-processors": "^2.0.0",
49
56
  "eslint-plugin-antfu": "^3.1.1",
50
- "eslint-plugin-import-x": "^4.6.1",
51
- "eslint-plugin-jsonc": "^2.19.1",
52
- "eslint-plugin-n": "^17.16.2",
57
+ "eslint-plugin-import-x": "^4.9.3",
58
+ "eslint-plugin-jsonc": "^2.20.0",
59
+ "eslint-plugin-n": "^17.17.0",
53
60
  "eslint-plugin-perfectionist": "^4.10.1",
54
61
  "eslint-plugin-react-hooks": "^5.2.0",
55
62
  "eslint-plugin-react-refresh": "^0.4.19",
56
63
  "eslint-plugin-regexp": "^2.7.0",
57
64
  "eslint-plugin-toml": "^0.12.0",
58
- "eslint-plugin-unicorn": "^57.0.0",
65
+ "eslint-plugin-unicorn": "^58.0.0",
59
66
  "eslint-plugin-unused-imports": "^4.1.4",
60
67
  "eslint-plugin-yml": "^1.17.0",
61
68
  "globals": "^16.0.0",
@@ -68,14 +75,14 @@
68
75
  "devDependencies": {
69
76
  "@eslint/config-inspector": "^1.0.2",
70
77
  "@prettier/plugin-xml": "^3.4.1",
71
- "@types/node": "^22.13.10",
78
+ "@types/node": "^22.13.14",
72
79
  "@unocss/eslint-plugin": "66.1.0-beta.3",
73
- "bumpp": "^10.0.3",
74
- "eslint": "^9.22.0",
80
+ "bumpp": "^10.1.0",
81
+ "eslint": "^9.23.0",
75
82
  "eslint-plugin-format": "^1.0.1",
76
- "eslint-typegen": "^2.0.0",
77
- "lint-staged": "^15.4.3",
78
- "simple-git-hooks": "^2.11.1",
83
+ "eslint-typegen": "^2.1.0",
84
+ "lint-staged": "^15.5.0",
85
+ "simple-git-hooks": "^2.12.1",
79
86
  "tsup": "^8.4.0",
80
87
  "tsx": "^4.19.3",
81
88
  "typescript": "^5.8.2"