Custom hook
Also written: useCart
Your own function whose name starts with `use` and that calls other hooks. `useCart()` wraps `useContext` and throws a clear error when used outside the provider.
Also written: useCart
Your own function whose name starts with `use` and that calls other hooks. `useCart()` wraps `useContext` and throws a clear error when used outside the provider.