arrow_backBACK TO DRILLS
White BeltimmutabilitylockPREMIUM

Array mutation with push

A component stores an array in state and adds items like this:

REACT_MODULE // 0x42
artists.push(newArtist);

The UI does not update after clicking "Add". Why?

lock

This Drill is Locked

This is a premium drill. Continue on to the next free drill in the sequence.

CONTINUE DRILLarrow_forward
BugDojo
BlogFAQ

© 2026. Carved in code.