In this lesson I refactor a React component that uses local state to use Unstated. Unstated provides a very nice and straight-forward API to help you manage global state painlessly.
Additional Resources:
Small addendum after recording this video, I should have named the item
property in the render prop function something more explicit to denote it's coming from a container / store. I think a better name for this property would have been itemStore
.
Ie: itemStore.state.items or itemStore.add()