Sporades SDK API
    Preparing search index...

    Type Alias HookPrimitives

    Framework primitives consumed by createHooks().

    Pass useState and useEffect from the JSX framework used by the Capsule client, such as React or Preact.

    type HookPrimitives = {
        useEffect(effect: () => void | (() => void), deps?: unknown[]): void;
        useState<State>(
            initialState: State | (() => State),
        ): [State, (nextState: State) => void];
    }
    Index
    • Parameters

      • effect: () => void | (() => void)
      • Optionaldeps: unknown[]

      Returns void