docs: fix explanation of Injectable decorator in architecture guide (#27480) (#28423)

PR Close #27480

PR Close #28423
This commit is contained in:
Stepan Suvorov 2019-01-16 15:11:48 +01:00 committed by Matias Niemelä
parent 495f8e1bc6
commit 728d903a67

View File

@ -73,7 +73,7 @@ Angular provides predefined pipes for common transformations, and you can also d
## Services and dependency injection
For data or logic that isn't associated with a specific view, and that you want to share across components, you create a *service* class. A service class definition is immediately preceded by the `@Injectable()` decorator. The decorator provides the metadata that allows your service to be *injected* into client components as a dependency.
For data or logic that isn't associated with a specific view, and that you want to share across components, you create a *service* class. A service class definition is immediately preceded by the `@Injectable()` decorator. The decorator provides the metadata that allows other providers to be **injected** as dependencies into your class.
*Dependency injection* (DI) lets you keep your component classes lean and efficient. They don't fetch data from the server, validate user input, or log directly to the console; they delegate such tasks to services.