import * as React from "react"; export interface CreateContextOptions { /** * If `true`, React will throw if context is `null` or `undefined` * In some cases, you might want to support nested context, so you can set it to `false` */ strict?: boolean; /** * Error message to throw if the context is `undefined` */ errorMessage?: string; /** * The display name of the context */ name: string; /** * The display name of the context */ initialValue?: Initial | undefined; } type CreateContextReturn = [React.Provider, () => T, React.Context] & { Provider: React.Provider; hook: () => T; Context: React.Context; Consumer: React.Consumer; }; /** * Creates a named context, provider, and hook. * * @param options create context options */ export declare function createContextWithHook(options: CreateContextOptions): CreateContextReturn; export declare function createContextWithHook(name: string, options?: CreateContextOptions): CreateContextReturn; export {}; //# sourceMappingURL=createContextWithHook.d.ts.map