Context Selector Pattern
Implement a simple selector hook that only re-renders when a slice of context changes.
Welcome
In this lesson you will implement a context selector hook that subscribes a component to only a slice of context state, preventing re-renders when unrelated parts of the context change.
The Selector Problem
useContext re-renders when ANY part of the context changes. If a component only needs the user's name but the context also holds a notifications list, adding a notification re-renders the name component unnecessarily.