egghead.io lesson 3: Simplifying deep updates with _produce_
Hosted on egghead.io
The Immer package exposes a default function that does all the work.
produce(currentState, producer: (draftState) => void): nextState
There is also a curried overload that is explained in a later section.
The interesting thing about Immer is that the
baseState will be untouched, but the
nextState will reflect all changes made to