Repository navigation
v3.0.0-rc.5
Pre-releaseMinor Changes
-
#65
cd7d1d9Thanks @stevensacks! - Added: four rule sets that close gaps in the bundle.baseturns on the type-aware@typescript-eslint/no-unsafe-call,no-unsafe-member-access,no-unsafe-argument,no-deprecatedandno-unnecessary-type-conversion, completing theno-unsafe-*family. Tests and stories keep theno-unsafe-*relaxation they already had.baseadds@eslint-community/eslint-comments: everyeslint-disablemust give a reason after--(// eslint-disable-next-line no-console -- startup banner), a bare blanketeslint-disableis banned, and block disables must be paired with an enable unless they cover the whole file.guardrailsaddseslint-plugin-regexp's recommended set, which catches patterns that backtrack catastrophically (ReDoS), alternatives that can never match and needless escapes.reactaddsreact-refresh/only-export-components, so a component module that also exports non-components, which breaks Fast Refresh, is reported.reactRouterallows React Router's route-module exports (loader,action,meta, ...) in route modules androot.tsx, and theshadcnvendored-ui exemption turns the rule off for registry files.
Action required on upgrade: add a
-- reasonto eacheslint-disablethat lacks one, and move any non-component export out of a component module. -
#66
8a1ecf4Thanks @stevensacks! - Added:reactreports Effects that should not be Effects (react-you-might-not-need-an-effect: state derived from other state or props, user-event logic in an Effect, chained updates, notifying a parent, resetting state on a prop change instead of usingkey). It also adds nine@eslint-reactrules: an Effect that adds a listener, timer, interval, observer or fetch must clean it up, and React 19 forms replaceforwardRef,useContextand<Context.Provider>.Added: two opt-in arrays.
lint.i18nreports raw JSX text that should come fromt(); spread it only if the UI is translated.lint.zodturns oneslint-plugin-zod's recommended rules for Zod 4 projects, minusconsistent-import.Changed: the
.length && <JSX/>selector's comment now says thatsonarjs/jsx-no-leaked-renderalready catches the generalcount && <JSX/>case.