Lifecycle types
Scoped dependencies
scoped resolves against the active request scope (AsyncLocalStorage on Node) or an explicit scope object:
Singleton TTL
Optionalttl (milliseconds) expires cached singletons lazily on the next resolve:
Immutable integrity
immutable providers are cached permanently. In development, verifyImmutableIntegrity() returns a checker that warns if the same token resolves to different object references:
Garbage collector
Evict idle scoped/singleton wrappers from internal caches:Cache invalidation
Parent containers
Child containers inherit unresolved tokens fromparent. Register overrides on the child; resolves fall through to the parent when the token is not local.