• Overview
@angular/core

Service

decorator

Decorator that marks a class as a service and makes it automatically available in the dependency injection system.

API

@Service();
@Service(options: { autoProvided: false });
@Service(options: { autoProvided?: true; factory: () => T });
@Service(options?: { autoProvided?: true });
Jump to details