@dynamic-labs/sdk-react-core
Version:
A React SDK for implementing wallet web3 authentication and authorization to your website.
23 lines (22 loc) • 838 B
TypeScript
import { FC, ReactElement } from 'react';
type IReinitializeContext = {
reinitialize: () => void;
key: string | undefined;
};
export declare const reinitializeContext: import("react").Context<IReinitializeContext | undefined>;
type ReinitializeContextProviderProps = {
children: ReactElement;
onReinitialize?: (key: string) => void;
};
/**
* Provider that provides a reinitialize function to its children.
* @param children The children to render.
* @param onReinitialize A callback that is called when reinitialize is called.
*/
export declare const ReinitializeContextProvider: FC<ReinitializeContextProviderProps>;
/**
* Custom hook that provides an reinitialize function for the DynamicContextProvider.
* @returns The reinitialize function.
*/
export declare const useReinitialize: () => () => void;
export {};