docs(cheatsheet): update to new syntax
See https://github.com/angular/angular.io/pull/459 Closes #5733
This commit is contained in:

committed by
Pete Bacon Darwin

parent
ca73852746
commit
2f0744b089
@ -6,27 +6,37 @@ Component configuration
|
||||
so the `@Directive` configuration applies to components as well
|
||||
|
||||
@cheatsheetItem
|
||||
syntax:
|
||||
`viewProviders: [MyService, provide(...)]`|`viewProviders:`
|
||||
description:
|
||||
Array of dependency injection providers scoped to this component's view.
|
||||
|
||||
|
||||
@cheatsheetItem
|
||||
syntax:
|
||||
`template: 'Hello {{name}}'
|
||||
templateUrl: 'my-component.html'`|`template:`|`templateUrl:`
|
||||
description:
|
||||
Inline template / external template url of the component's view.
|
||||
|
||||
|
||||
@cheatsheetItem
|
||||
syntax:
|
||||
`styles: ['.primary {color: red}']
|
||||
styleUrls: ['my-component.css']`|`styles:`|`styleUrls:`
|
||||
description:
|
||||
List of inline css styles / external stylesheet urls for styling component’s view.
|
||||
|
||||
|
||||
@cheatsheetItem
|
||||
syntax:
|
||||
`directives: [MyDirective, MyComponent]`|`directives:`
|
||||
description:
|
||||
List of directives used in the the component’s template.
|
||||
|
||||
|
||||
@cheatsheetItem
|
||||
syntax:
|
||||
`pipes: [MyPipe, OtherPipe]`|`pipes:`
|
||||
description:
|
||||
List of pipes used in the component's template.
|
Reference in New Issue
Block a user