Function provide

  • Registers a creator function for a given key.

    Type Parameters

    • T = object

    Parameters

    • key: Key

      The key to associate with the creator function.

    • ctor: (() => T | Promise<T>)

      The creator function that returns the desired object or a promise resolving to the desired object.

        • (): T | Promise<T>
        • Returns T | Promise<T>

    Returns void