Skip to content

DI Bag API / index / Presence

Type Alias: Presence<T> ​

ts
type Presence<T> = {
    readonly isPresent: false;
} | {
    readonly isPresent: true;
    readonly value: T;
};

Defined in: inspection.ts:8

Structural optional presence; payloads are application-owned and not frozen.

Type Parameters ​

Type ParameterDescription
T-

See ​

https://dany-fedorov.github.io/di-bag/guides/tutorial.html#attach-metadata-and-inspect-without-resolving

Ordinary services. Checked composition. Explicit ownership.