Type Alias ValidProviderDependencies<Deps, Dm>

ValidProviderDependencies<Deps, Dm>: {
    readonly [K in keyof Deps]: K extends keyof Dm
        ? ProvidedType<Dm[K]> extends Deps[K]
            ? K extends FlattenDependencies<K, Dm>
                ? NeverCyclicDependency<K, FlattenDependencies<K, Dm>>
                : Deps[K]
            : NeverWrongDependencyType<ProvidedType<Dm[K]>, Deps[K]>
        : MissingDependency<K>
}

Validate that the dependencies of a factory are not cyclical and that the return type of the dependency is a subtype of what's needed.

Type Parameters

  • Deps
  • Dm