Circus
    Preparing search index...

    Interface IZCircusReactHook<T, P>

    Represents a driver for a react hook.

    interface IZCircusReactHook<T, P> {
        current(): Promise<T>;
        destroy(): Promise<void>;
        rerender(props?: P): Promise<T>;
    }

    Type Parameters

    • T
    • P

    Implemented by

    Index

    Methods

    • Destroys the hook.

      This call is optional. Hooks will be destroyed automatically when the test framework is unmounted. This is useful for testing use cases of a hook after the parent component has been unmounted.

      Returns Promise<void>

    • Rerenders the underlying hook and gives the results.

      Parameters

      • Optionalprops: P

      Returns Promise<T>

      The current value after the render.