()
| 4 | import { UserContext } from '@/contexts/user-context'; |
| 5 | |
| 6 | export function useUser(): UserContextValue { |
| 7 | const context = React.useContext(UserContext); |
| 8 | |
| 9 | if (!context) { |
| 10 | throw new Error('useUser must be used within a UserProvider'); |
| 11 | } |
| 12 | |
| 13 | return context; |
| 14 | } |
no outgoing calls
no test coverage detected