If a Redux action deletes a todo while a child component still has that todo’s ID in its props, a prop-dependent selector can briefly look up a record that no longer exists. That edge case is called the zombie child problem. React-Redux documents it, but describes it as rare—not as evidence that Redux is generally broken. Zustand’s official introduction says the library addressed the pitfall, though that statement alone does not prove it is the better choice for every app.
How a deleted todo can become a zombie child
Imagine a parent renders a child for todo ID 42. The child reads the todo from the store using its ID prop. An action deletes todo 42 and also changes the parent’s data so that the parent should stop rendering that child.
As an Amazon Associate I earn from qualifying purchases.
The problem is subscription order. If the child’s store subscription runs before the parent’s update has removed the child, the child can still have its old props. Its selector then tries to read the deleted record. An unguarded lookup may fail or produce incorrect data. React-Redux describes this as a stale-props or zombie-child case when selectors depend on props. React-Redux’s hooks documentation explains the edge case.
Outdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware matchPC Slower Than It Used to Be?
A free scan shows the junk files, broken settings and background clutter dragging Windows down - then fixes them in one click.Free scan · Windows 10 & 11Which Redux subscription model is involved?
Hooks: selectors can see stale props
React-Redux’s hooks API does not create the same nested subscription hierarchy that connect() creates. A hook-based component can therefore encounter stale props or a zombie child in some update sequences. The documentation calls these situations rare in practice, and the risk is especially relevant when a selector uses props to access an entity that may be removed.
#1 Best Overall
connect(): nested subscriptions order updates
React-Redux’s connect() creates nested subscriptions through context. A connected ancestor can delay notifications to descendants until that ancestor has updated, helping ensure a child does not select against props that its parent is about to invalidate. The same documentation describes this distinction.
Redux recommends hooks as the default for components while continuing to support connect(). Using connect() immediately above a component that uses useSelector() is one documented way to restore relevant nested ordering when both are updated by the same action. React-Redux’s store-access documentation covers the supported APIs.
Rank #2
How to make a prop-dependent selector safer
Do not assume an entity still exists just because its ID is present in props. Read the entity first, then handle the missing case before accessing its fields.
const todo = useSelector(state => state.todos[props.id]);
return todo ? <span>{todo.name}</span> : null;
This pattern makes deletion an expected state rather than an exceptional one. Selectors should remain pure and should not rely on thrown errors as application control flow. React-Redux notes that useSelector() attempts to handle selector errors during store updates by forcing a render, where the selector runs again; that behavior is not a substitute for a defensive lookup. See the hooks documentation and the useSelector() API guidance.
What Zustand’s claim does—and does not—establish
Zustand’s official introduction says the library spent time addressing common pitfalls including the zombie-child problem, React concurrency, and context loss between mixed renderers. That supports saying Zustand explicitly addresses this pitfall. It does not establish that every Zustand application is immune to every stale-data bug, or that Zustand is faster or safer for every workload. Zustand’s official introduction provides the stated rationale.
| Question | What the available documentation supports |
|---|---|
| Does React-Redux document zombie children? | Yes. The hooks documentation describes stale-props and zombie-child cases involving prop-dependent selectors. |
Does connect() affect subscription ordering? |
Yes. It creates nested subscriptions that can delay descendant notifications until an ancestor updates. |
| Does Zustand say it addressed the pitfall? | Yes. Its introduction makes that broad claim. |
| Is there evidence here that Zustand always wins on performance or safety? | No. The cited sources do not provide a direct benchmark or prove universal superiority. |
Keep selector rerenders separate from zombie children
A selector that returns a new object on every call can cause rerenders even when the object’s fields have not changed. By default, useSelector() compares the previous and next selected values with strict === reference equality. Prefer stable selections, memoized derivations, or an appropriate equality strategy when returning composite values. This is a selector-stability concern, not the subscription-ordering bug described above. React-Redux explains equality comparisons; Redux’s selector guidance discusses derived data.
Quick Recap
Best Value
When the distinction should guide your choice
- Choose based on your architecture, not the label “zombie child.” If using React-Redux hooks, keep prop-dependent entity lookups defensive and account for entities being deleted.
- Consider
connect()where nested ordering matters. It remains supported and provides the subscription hierarchy hooks do not. - Consider Zustand if its API and state model fit your app. Its introduction says it addressed this pitfall, but that claim is not a complete comparative evaluation.
- Do not treat a render count or a rare edge case as a universal verdict. The sources establish neither a cross-library performance winner nor a categorical safety ranking.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →




