Context

The object returned from createContext(). This object is very similar to the Context object returned by React's own createContext(), but with a little sugar added.

Definition

interface Context<TWrappedContainer> {
  Provider: Component

  provide(component: ComponentType): Component

  Consumer: Component

  consume(
    mapStoreToProps?: string | string[] | ((store: WrappedStateContainer) => Object)
  ): (component: ComponentType) => Component

  Injector: Component

  inject(
    mapStoreToProps?: string | string[] | ((store: WrappedStateContainer) => Object)
  ): (component: ComponentType) => Component
}

Properties

Provider

provide

Consumer

consume

Injector

inject

results matching ""

    No results matching ""