docs: list supported values for `read` in decorator metadata (#42370)
fixes #20927 PR Close #42370
This commit is contained in:
parent
e798bfabb0
commit
1b8bbddff5
|
@ -154,6 +154,13 @@ export interface ContentChildrenDecorator {
|
||||||
* removed in future versions of Angular.
|
* removed in future versions of Angular.
|
||||||
* * **read** - Used to read a different token from the queried elements.
|
* * **read** - Used to read a different token from the queried elements.
|
||||||
*
|
*
|
||||||
|
* The following values are supported by `read`:
|
||||||
|
* * Any class with the `@Component` or `@Directive` decorator
|
||||||
|
* * Any provider defined on the injector of the component that is matched by the `selector` of
|
||||||
|
* this query
|
||||||
|
* * Any provider defined through a string token (e.g. `{provide: 'token', useValue: 'val'}`)
|
||||||
|
* * `TemplateRef`, `ElementRef`, and `ViewContainerRef`
|
||||||
|
*
|
||||||
* @usageNotes
|
* @usageNotes
|
||||||
*
|
*
|
||||||
* Here is a simple demonstration of how the `ContentChildren` decorator can be used.
|
* Here is a simple demonstration of how the `ContentChildren` decorator can be used.
|
||||||
|
@ -230,6 +237,13 @@ export interface ContentChildDecorator {
|
||||||
* * **static** - True to resolve query results before change detection runs,
|
* * **static** - True to resolve query results before change detection runs,
|
||||||
* false to resolve after change detection. Defaults to false.
|
* false to resolve after change detection. Defaults to false.
|
||||||
*
|
*
|
||||||
|
* The following values are supported by `read`:
|
||||||
|
* * Any class with the `@Component` or `@Directive` decorator
|
||||||
|
* * Any provider defined on the injector of the component that is matched by the `selector` of
|
||||||
|
* this query
|
||||||
|
* * Any provider defined through a string token (e.g. `{provide: 'token', useValue: 'val'}`)
|
||||||
|
* * `TemplateRef`, `ElementRef`, and `ViewContainerRef`
|
||||||
|
*
|
||||||
* @usageNotes
|
* @usageNotes
|
||||||
*
|
*
|
||||||
* {@example core/di/ts/contentChild/content_child_howto.ts region='HowTo'}
|
* {@example core/di/ts/contentChild/content_child_howto.ts region='HowTo'}
|
||||||
|
@ -293,6 +307,13 @@ export interface ViewChildrenDecorator {
|
||||||
* ** Note: *** This config option is **deprecated**, it will be permanently set to `true` and
|
* ** Note: *** This config option is **deprecated**, it will be permanently set to `true` and
|
||||||
* removed in future versions of Angular.
|
* removed in future versions of Angular.
|
||||||
*
|
*
|
||||||
|
* The following values are supported by `read`:
|
||||||
|
* * Any class with the `@Component` or `@Directive` decorator
|
||||||
|
* * Any provider defined on the injector of the component that is matched by the `selector` of
|
||||||
|
* this query
|
||||||
|
* * Any provider defined through a string token (e.g. `{provide: 'token', useValue: 'val'}`)
|
||||||
|
* * `TemplateRef`, `ElementRef`, and `ViewContainerRef`
|
||||||
|
*
|
||||||
* @usageNotes
|
* @usageNotes
|
||||||
*
|
*
|
||||||
* {@example core/di/ts/viewChildren/view_children_howto.ts region='HowTo'}
|
* {@example core/di/ts/viewChildren/view_children_howto.ts region='HowTo'}
|
||||||
|
@ -368,6 +389,13 @@ export interface ViewChildDecorator {
|
||||||
* * A `TemplateRef` (e.g. query `<ng-template></ng-template>` with `@ViewChild(TemplateRef)
|
* * A `TemplateRef` (e.g. query `<ng-template></ng-template>` with `@ViewChild(TemplateRef)
|
||||||
* template;`)
|
* template;`)
|
||||||
*
|
*
|
||||||
|
* The following values are supported by `read`:
|
||||||
|
* * Any class with the `@Component` or `@Directive` decorator
|
||||||
|
* * Any provider defined on the injector of the component that is matched by the `selector` of
|
||||||
|
* this query
|
||||||
|
* * Any provider defined through a string token (e.g. `{provide: 'token', useValue: 'val'}`)
|
||||||
|
* * `TemplateRef`, `ElementRef`, and `ViewContainerRef`
|
||||||
|
*
|
||||||
* @usageNotes
|
* @usageNotes
|
||||||
*
|
*
|
||||||
* {@example core/di/ts/viewChild/view_child_example.ts region='Component'}
|
* {@example core/di/ts/viewChild/view_child_example.ts region='Component'}
|
||||||
|
|
Loading…
Reference in New Issue