13 lines
303 B
TypeScript
13 lines
303 B
TypeScript
import { useContext } from 'react';
|
|
import { ManageKycContext } from './ManageKycContext';
|
|
|
|
const useKycContext = () => {
|
|
const context = useContext(ManageKycContext);
|
|
|
|
if (!context) throw new Error('useKycContext must be used within AuthProvider');
|
|
|
|
return context;
|
|
};
|
|
|
|
export { useKycContext };
|