~/talk

Reducing bugs in a React codebase

Talkat React Native EU 2022 · 2022-09-01..09-02· [react, frontend-architecture]
links:none on file
slides:none on file

Shows concrete fixes: debugging starts with random print statements, React DevTools and browser DevTools, then moves to preventive refactors that drop heavy useState usage to 0.35 useState per component across a codebase of 112 custom hooks and 192 components. Replaces state-without-deps anti-patterns (props-as-initial-state) with useReducer and useMemo and local refs/controlled components, avoids destroy-and-recreate keyed remounts that cause flicker, and enforces single-source-of-truth to stop partial or unexpected renders.

AI-written summary · about

  1. 0:00Introduction and background
  2. 1:00Identifying React anti-patterns
  3. 2:31Common component bugs
  4. 3:41React dependency principles
  5. 5:00Case study of bug patterns
  6. 9:08Optimizing state management
  7. 11:09Nesting and conclusion
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.