React Doctor
492 rules react-doctor@0.9.14
Complete effective rule inventory.
Rules
No enabled React Doctor rules match this search.
-
react-doctor/remotion-deterministic-randomnessUse Remotion's seeded
random(seed)helper so the same frame produces the same value in every render tab.: error in React projects -
react-doctor/remotion-no-css-animationDrive the property from
useCurrentFrame()withinterpolate()so every rendered frame is deterministic.: error in React projects -
react-doctor/remotion-no-css-transitionDrive the property from
useCurrentFrame()withinterpolate()so every rendered frame is deterministic.: error in React projects -
react-doctor/remotion-no-css-url-assetsRender the asset with
Imginside anAbsoluteFill, or preload the same source with a hiddenImgwhen a CSS mask is required.: error in React projects -
react-doctor/remotion-no-module-scope-delay-renderCreate the handle once inside the component. Use
useDelayRender()on Remotion 4.0.342 or newer, or lazyuseState(() => delayRender())on earlier versions.: error in React projects -
react-doctor/remotion-no-native-media-elementsUse Remotion's media components so rendering waits for assets and seeks media to the requested frame.
: error in React projects -
react-doctor/remotion-no-next-imageUse
Imgfromremotion, which delays rendering until the image is loaded.: error in React projects -
react-doctor/remotion-stable-delay-render-handlePrefer
useDelayRender(), or initializedelayRender()once withuseState(() => delayRender()).: error in React projects -
react-doctor/rendering-conditional-renderUse
{items.length > 0 && <List />}, or a ternary like{items.length ? <List /> : null}.: warning in React projects -
react-doctor/rendering-hydration-mismatch-timeMove time or random values into useEffect+useState so they only run in the browser, or add suppressHydrationWarning to the parent if it's intentional
: warning in React projects -
react-doctor/repository-secret-fileRemove committed env files, service-account credentials, npm auth tokens, and webhook URLs; rotate exposed values and keep only redacted examples in source.
: error in React projects -
react-doctor/request-body-mass-assignmentAssign explicit, allowlisted fields (or validate with a strict schema and no
.passthrough()) instead of spreading/merging request input. Otherwise the client can set ownership, role, or price columns (mass assignment) or pollute the prototype.: warning in React projects -
react-doctor/require-render-returnReturn JSX or
nullfromrenderso the component intentionally shows something or nothing.: error in React projects -
react-doctor/rn-bottom-sheet-no-ignored-scroll-propRemove scrollEventThrottle, decelerationRate, and onScrollBeginDrag from BottomSheetScrollView because the component ignores them.
: warning in React Native projects -
react-doctor/rn-bottom-sheet-no-state-in-on-animateAvoid starting React renders from onAnimate. Use animatedIndex or animatedPosition for animation-coupled UI, or onChange for committed index state.
: warning in React Native projects -
react-doctor/rn-bottom-sheet-use-integrated-scrollableUse @gorhom/bottom-sheet's integrated BottomSheetScrollView, BottomSheetFlatList, BottomSheetSectionList, or BottomSheetVirtualizedList so gestures coordinate with the sheet.
: warning in React Native projects -
react-doctor/rn-detox-missing-awaitPrepend
awaitto Detox actions,waitFor(...)chains, andexpect(element(...))assertions. They return promises tied to Detox's synchronization, so a missing await runs steps out of order.: warning in React Native projects -
react-doctor/rn-no-deep-importsImport the symbol from
react-native(the package root) instead of the deprecatedreact-native/Libraries/...subpath, which RFC 0894 removes on upgrade.: warning in React Native projects -
react-doctor/rn-no-falsy-and-renderWhen the number is 0, this shows a bare
0as text, which crashes on RN. Use{value > 0 && <X />},{Boolean(value) && <X />}, or{value ? <X /> : null}.: error in React Native projects -
react-doctor/rn-no-image-childrenReact Native's
<Image>can't render children. Use<ImageBackground>(samesource/styleprops) to layer content over an image.: error in React Native projects -
react-doctor/rn-reanimated-4-no-legacy-spring-thresholdsReplace Reanimated 3 rest thresholds with Reanimated 4's
energyThresholdspring option.: warning in React Native projects -
react-doctor/rn-reanimated-4-no-removed-apiMigrate removed Reanimated APIs to their Reanimated 4 or Gesture API replacements before upgrading.
: warning in React Native projects -
react-doctor/rn-reanimated-4-use-worklets-schedulerImport the corresponding scheduler from
react-native-workletswhen migrating to Reanimated 4.: warning in React Native projects -
react-doctor/role-button-requires-complete-keyboard-activationUse a native button, or make a custom role button activate with both Enter and Space.
: warning in React projects -
react-doctor/role-has-required-aria-propsAdd every required
aria-*attribute so assistive tech can expose the role's state correctly.: error in React projects -
react-doctor/role-supports-aria-propsOnly use
aria-*attributes that the element's role supports.: warning in React projects -
react-doctor/scopeRemove
scopefrom this element or move it to the related<th>cell.: warning in React projects -
react-doctor/secret-in-fallbackRemove the literal fallback and fail closed (throw when the variable is unset). The hardcoded value is a committed secret, and the
??/||default makes the app run with it in any environment that forgot to set the var.: error in React projects -
react-doctor/server-auth-actionsCheck auth before changing server state or invoking billable services because exported server actions can be called directly by unauthenticated clients.
: error in React projects -
react-doctor/server-fetch-without-revalidatePass
{ next: { revalidate: <seconds> } }(orcache: "no-store") so old data doesn't stick around.: warning in React projects -
react-doctor/server-no-mutable-module-stateKeep per-request data inside the action, or in headers, cookies, or
React.cache. Module-scopelet/varis shared by every request.: error in React projects -
react-doctor/shadcn-command-item-state-variant-requires-valueStyle command items with the value-aware variants data-[selected=true]: and data-[disabled=true]:, because cmdk renders both attributes on every item as "true" or "false".
: warning in React projects -
react-doctor/shadcn-dialog-content-requires-titleGive every DialogContent, SheetContent, AlertDialogContent, and DrawerContent a matching title part (wrapped in an sr-only element when the design shows no heading) or name the dialog with aria-label.
: warning in React projects -
react-doctor/shadcn-form-item-requires-labelGive every FormItem that wraps a FormControl a FormLabel (sr-only when the design shows no visible label) or name the control directly with aria-label.
: warning in React projects -
react-doctor/shadcn-icon-button-requires-labelGive every icon-sized Button an aria-label or an sr-only text child so assistive technology announces what the button does.
: warning in React projects -
react-doctor/shadcn-input-group-no-raw-controlsCompose InputGroup from its own parts (InputGroupInput, InputGroupTextarea, and InputGroupAddon with InputGroupButton) so the group owns one border, focus ring, and error state.
: warning in React projects -
react-doctor/shadcn-tabs-trigger-requires-listRender each imported TabsTrigger inside its library TabsList so keyboard navigation and tablist semantics share one scope.
: warning in React projects -
react-doctor/style-prop-objectPass
styleas an object so React can apply CSS properties instead of ignoring a string style value.: warning in React projects -
react-doctor/styled-components-non-transient-custom-prop-on-intrinsic-elementPrefix custom styled-components props with
$(e.g.$active) so styled-components v6 keeps them off the DOM node instead of forwarding them as invalid attributes.: warning in React projects -
react-doctor/supabase-client-owned-authz-fieldUse RLS policies based on
auth.uid()and server-owned membership rows; do not trust client-provided owner, org, or role columns.: error in React projects