react-hooks-global-states 12.0.0 → 12.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/createContext.d.ts +1 -1
- package/package.json +1 -1
package/createContext.d.ts
CHANGED
|
@@ -478,5 +478,5 @@ export declare const createContext: CreateContext;
|
|
|
478
478
|
* ContextApi<number, React.Dispatch<React.SetStateAction<number>>, BaseMetadata>;
|
|
479
479
|
* ```
|
|
480
480
|
*/
|
|
481
|
-
export type InferContextApi<Context extends ReactContext<ContextHook<any, any,
|
|
481
|
+
export type InferContextApi<Context extends ReactContext<ContextHook<any, any, any> | null>> = NonNullable<React.ContextType<Context>> extends ContextHook<infer State, infer StateMutator, infer Metadata> ? StateApi<State, StateMutator extends AnyFunction ? null : StateMutator, Metadata> : never;
|
|
482
482
|
export default createContext;
|
package/package.json
CHANGED