@jsse/eslint-config 0.9.6 → 0.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/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # @jsse/eslint-config
2
2
 
3
+ ## 0.9.7
4
+ ### Patch Changes
5
+
6
+ - internal refactoring and version updates
7
+
3
8
  ## 0.9.6
4
9
  ### Patch Changes
5
10
 
package/README.md CHANGED
@@ -76,7 +76,7 @@ export default jsse({
76
76
  | ----------------- | ------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
77
77
  | `typescript` | auto-detect | Enabled when `typescript` is installed. Accepts `{ presets, tsconfig, overrides }`. Passing `{ tsconfig }` enables type-aware rules unless `typeAware: false` is set. |
78
78
  | `typeAware` | `false` | Explicit override for type-aware TypeScript rules. |
79
- | `react` | `false` | Enables React rules; accepts `refresh`, `preset`, and `overrides`. TS/TSX parsing comes entirely from `typescript`/`tsconfig`. |
79
+ | `react` | `false` | Enables React rules; accepts `hooks`, `refresh`, `eslintReactPreset`, and `overrides`. TS/TSX parsing comes entirely from `typescript`/`tsconfig`. |
80
80
  | `reactRefresh` | `true` when `react` is enabled | Legacy top-level alias. Prefer `react.refresh: false` to disable React Refresh rules. |
81
81
  | `antfu` | `true` | Enables `eslint-plugin-antfu`; accepts `topLevelFunction` and `overrides`. |
82
82
  | `demorgan` | `true` | Enables `eslint-plugin-de-morgan`; accepts `overrides`. |
@@ -129,19 +129,17 @@ Preset names match `typescript-eslint`'s kebab-case config names: `recommended`,
129
129
  The older `typescript.strict` option is still supported for compatibility, but
130
130
  new configs should use `presets`.
131
131
 
132
- ### React Preset
132
+ ### `@eslint-react` Preset
133
133
 
134
- The `react.preset` option selects the upstream `@eslint-react/eslint-plugin`
135
- preset rules before user overrides are applied. It defaults to `"recommended"`.
134
+ The `react.eslintReactPreset` option selects the upstream
135
+ `@eslint-react/eslint-plugin` preset rules before user overrides are applied.
136
+ It's named `eslintReactPreset` rather than `preset` because `@eslint-react` is a
137
+ separate plugin from `eslint-plugin-react-hooks`/`eslint-plugin-react-refresh`
138
+ (the `hooks`/`refresh` options), not "React config as a whole." It defaults to
139
+ `"recommended"`.
136
140
 
137
141
  ```js
138
- jsse({ react: { preset: "strict-type-checked" } });
139
- ```
140
-
141
- React Refresh can be disabled with `react.refresh`:
142
-
143
- ```js
144
- jsse({ react: { refresh: false } });
142
+ jsse({ react: { eslintReactPreset: "strict-type-checked" } });
145
143
  ```
146
144
 
147
145
  Preset names match `@eslint-react`'s kebab-case config names: `recommended`,
@@ -151,6 +149,25 @@ this only accepts a single preset — the `@eslint-react` presets are mutually
151
149
  exclusive points on one severity/TS-awareness scale rather than composable
152
150
  layers (`strict` is already a superset of `recommended`'s rules).
153
151
 
152
+ ### React Hooks & React Refresh Presets
153
+
154
+ `react.hooks` and `react.refresh` can each be `false` (disable), `true` (enable
155
+ with the default preset), or one of that plugin's own preset names:
156
+
157
+ ```js
158
+ jsse({
159
+ react: {
160
+ hooks: "recommended-latest", // eslint-plugin-react-hooks; default
161
+ refresh: "vite", // eslint-plugin-react-refresh; default is "recommended"
162
+ },
163
+ });
164
+ ```
165
+
166
+ `eslint-plugin-react-hooks` ships `recommended` and `recommended-latest`.
167
+ `eslint-plugin-react-refresh` ships `recommended`, `vite`, and `next` — only
168
+ `recommended` and `vite` are supported here; `next`'s `allowExportNames`
169
+ allowlist is Next.js-specific and out of scope for this config.
170
+
154
171
  ## Thanks
155
172
 
156
173
  - [antfu](https://github.com/antfu) and [sxzz](https://github.com/sxzz) for
@@ -175,3 +192,10 @@ formatter/linter/code style to my liking, but I really don't care anymore...
175
192
 
176
193
  [package-url]: https://www.npmjs.com/package/@jsse/eslint-config
177
194
  [npm-version-svg]: https://badge.fury.io/js/@jsse%2Feslint-config.svg
195
+
196
+ ---
197
+
198
+ ## Changelog (NOTABLE CHANGES)
199
+
200
+ <!-- <CHANGELOG> -->
201
+ <!-- </CHANGELOG> -->