Marks a property for lazy injection using the reflected property type.
This overload is only valid for properties because constructor parameters require an explicit service type.
Marks a property or constructor parameter for injection using the given type.
Type or lazy type resolver to resolve from the container.
Marks a property or constructor parameter to be created as a new instance.
The target type is taken from emitted decorator metadata. The new instance is created by the active container, so its own dependencies still use the same container context.
Constructor arguments passed to the injected type.
Decorator factory for container-managed constructor and property injection.
Use
@inject(Type)when a dependency should be resolved from the container. Use@inject.new(...args)when the dependency must be constructed as a new instance with explicit constructor arguments.