Skip to content

DI Bag API / index / Provider

Interface: Provider<ExposedFactory extends Factory, RegistrationMetadata extends object = Readonly<{ }>, AcquisitionMetadataFrames extends readonly unknown[] = readonly [], RetainedGraphContract extends GraphContract = TokenDependencyContract, AcquiredValue = Awaited<ReturnType<ExposedFactory>>> ​

Defined in: provider.ts:34

An immutable provider description retaining factory, metadata, inspection-frame, dependency-graph, and acquired-value contracts.

Create providers through DiBagApi.createProvider, composition adapters, or provider composition facades. This type-only class has no public constructor or instance methods.

See ​

https://dany-fedorov.github.io/di-bag/guides/api-reference.html#provider-and-module-projections

Extends ​

  • ProviderBase

Type Parameters ​

Type ParameterDescription
ExposedFactoryThe exact exposed factory signature, including named dependencies.
RegistrationMetadataStatic registration metadata available before resolution.
AcquisitionMetadataFramesThe ordered tuple of acquisition metadata frame payloads.
RetainedGraphContractThe retained token, lifetime, and graph compatibility contract.
AcquiredValueThe raw or fulfilled value supplied to an outer disposal stage.

Ordinary services. Checked composition. Explicit ownership.