You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently we directly access the context and it is better to access the context via a hook. Wrap the AsgardeoContext with a custom hook (ex: useAsgardeo)
const useBrandingPreference = (): UseBrandingPreferenceInterface => {
const context: BrandingPreferenceContextProps = useContext(BrandingPreferenceContext);
if (context === undefined) {
throw new Error("UseBrandingPreference must be used within a BrandingPreferenceProvider");
}
return context;
};
export default useBrandingPreference;
The text was updated successfully, but these errors were encountered:
Description:
Currently we directly access the context and it is better to access the context via a hook. Wrap the AsgardeoContext with a custom hook (ex: useAsgardeo)
The text was updated successfully, but these errors were encountered: