Used to retrieve the type of a context object from a Context.
The context object.
import { createContext } from 'react';const MyContext = createContext({ foo: 'bar' });type ContextType = ContextType<typeof MyContext>;// ContextType = { foo: string } Copy
import { createContext } from 'react';const MyContext = createContext({ foo: 'bar' });type ContextType = ContextType<typeof MyContext>;// ContextType = { foo: string }
Used to retrieve the type of a context object from a Context.