@xylabs/eslint-config-react-flat 7.9.5 → 7.9.7

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.body.md CHANGED
@@ -26,20 +26,28 @@ bun add -D {{name}}
26
26
 
27
27
  ## Usage
28
28
 
29
- Use this config in your `eslint.config.mjs`:
29
+ Use this config in your `eslint.config.ts`:
30
+
31
+ ```ts
32
+ import type { Linter } from 'eslint'
30
33
 
31
- ```js
32
34
  import { config } from '@xylabs/eslint-config-react-flat'
33
35
 
34
- export default config
36
+ const eslintConfig: Linter.Config[] = [
37
+ ...config,
38
+ ]
39
+
40
+ export default eslintConfig
35
41
  ```
36
42
 
37
43
  ### Extending with custom rules
38
44
 
39
- ```js
45
+ ```ts
46
+ import type { Linter } from 'eslint'
47
+
40
48
  import { config } from '@xylabs/eslint-config-react-flat'
41
49
 
42
- export default [
50
+ const eslintConfig: Linter.Config[] = [
43
51
  ...config,
44
52
  {
45
53
  rules: {
@@ -47,6 +55,8 @@ export default [
47
55
  },
48
56
  },
49
57
  ]
58
+
59
+ export default eslintConfig
50
60
  ```
51
61
 
52
62
  ## What's included
package/README.md CHANGED
@@ -29,17 +29,23 @@ pnpm add -D {{name}}
29
29
 
30
30
  ## Usage
31
31
 
32
- Use the compatibility export in your `eslint.config.mjs`:
32
+ Use the compatibility export in your `eslint.config.ts`:
33
+
34
+ ```ts
35
+ import type { Linter } from 'eslint'
33
36
 
34
- ```js
35
37
  import { config } from '@xylabs/eslint-config-react-flat'
36
38
 
37
- export default config
39
+ const eslintConfig: Linter.Config[] = [
40
+ ...config,
41
+ ]
42
+
43
+ export default eslintConfig
38
44
  ```
39
45
 
40
46
  For new consumers, prefer the explicit presets:
41
47
 
42
- ```js
48
+ ```ts
43
49
  import { recommendedTypeCheckedConfig } from '@xylabs/eslint-config-react-flat'
44
50
 
45
51
  export default recommendedTypeCheckedConfig
@@ -47,10 +53,12 @@ export default recommendedTypeCheckedConfig
47
53
 
48
54
  ### Extending with custom rules
49
55
 
50
- ```js
56
+ ```ts
57
+ import type { Linter } from 'eslint'
58
+
51
59
  import { config } from '@xylabs/eslint-config-react-flat'
52
60
 
53
- export default [
61
+ const eslintConfig: Linter.Config[] = [
54
62
  ...config,
55
63
  {
56
64
  rules: {
@@ -58,6 +66,8 @@ export default [
58
66
  },
59
67
  },
60
68
  ]
69
+
70
+ export default eslintConfig
61
71
  ```
62
72
 
63
73
  ## What's included
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xylabs/eslint-config-react-flat",
3
- "version": "7.9.5",
3
+ "version": "7.9.7",
4
4
  "description": "ESLint Config used throughout XY Labs TypeScript/JavaScript libraries and react projects",
5
5
  "keywords": [
6
6
  "xylabs",
@@ -36,7 +36,7 @@
36
36
  ],
37
37
  "dependencies": {
38
38
  "@typescript-eslint/parser": "~8.58.0",
39
- "@xylabs/eslint-config-flat": "~7.9.5",
39
+ "@xylabs/eslint-config-flat": "~7.9.7",
40
40
  "eslint-plugin-react-dom": "^4.2.3",
41
41
  "eslint-plugin-react-hooks": "^7.0.1",
42
42
  "eslint-plugin-react-naming-convention": "^4.2.3",
@@ -50,9 +50,9 @@
50
50
  "@babel/core": "^7.29.0",
51
51
  "@testing-library/dom": "^10.4.1",
52
52
  "@types/node": "^25.5.2",
53
- "@xylabs/ts-scripts-common": "~7.9.5",
54
- "@xylabs/ts-scripts-yarn3": "~7.9.5",
55
- "@xylabs/tsconfig": "~7.9.5",
53
+ "@xylabs/ts-scripts-common": "~7.9.7",
54
+ "@xylabs/ts-scripts-yarn3": "~7.9.7",
55
+ "@xylabs/tsconfig": "~7.9.7",
56
56
  "acorn": "^8.16.0",
57
57
  "cosmiconfig": "^9.0.1",
58
58
  "esbuild": "^0.28.0",