jor / src /context /useApp.ts
Mentor AMP Frontend
Refactor Volt frontend into feature pages and shared context
6e631f3
Raw History Blame Contribute Delete
236 Bytes
import { useContext } from 'react'
import { AppContext } from './context'
export function useApp() {
const context = useContext(AppContext)
if (!context) throw new Error('useApp must be used within AppProvider')
return context
}