parent
038d06d2e9
commit
5099b79545
@ -12,11 +12,11 @@ import {EmbeddedViewRef} from './view_ref';
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents an embedded template that can be used to instantiate embedded views.
|
* Represents an embedded template that can be used to instantiate embedded views.
|
||||||
* To instantiate embedded views based on a template, use {@link ViewContainerRef#
|
* To instantiate embedded views based on a template, use the `ViewContainerRef`
|
||||||
* createEmbeddedView}.
|
* method `createEmbeddedView()`.
|
||||||
*
|
*
|
||||||
* Access a `TemplateRef` instance by placing a directive (or directive prefixed with `*`)
|
* Access a `TemplateRef` instance by placing a directive on an `<ng-template>`
|
||||||
* on an `<ng-template>` element. The `TemplateRef` for the embedded view
|
* element (or directive prefixed with `*`). The `TemplateRef` for the embedded view
|
||||||
* is injected into the constructor of the directive,
|
* is injected into the constructor of the directive,
|
||||||
* using the `TemplateRef` token.
|
* using the `TemplateRef` token.
|
||||||
*
|
*
|
||||||
|
@ -17,9 +17,9 @@ import {EmbeddedViewRef, ViewRef} from './view_ref';
|
|||||||
/**
|
/**
|
||||||
* Represents a container where one or more views can be attached to a component.
|
* Represents a container where one or more views can be attached to a component.
|
||||||
*
|
*
|
||||||
* Can contain _host_ views (created by instantiating a
|
* Can contain *host views* (created by instantiating a
|
||||||
* component with the `createComponent()` method), and _embedded views_
|
* component with the `createComponent()` method), and *embedded views*
|
||||||
* (created by instantiating a `TemplateRef` with the `createEmbeddedView()` method.
|
* (created by instantiating a `TemplateRef` with the `createEmbeddedView()` method).
|
||||||
*
|
*
|
||||||
* A view container instance can contain other view containers,
|
* A view container instance can contain other view containers,
|
||||||
* creating a [view hierarchy](guide/glossary#view-tree).
|
* creating a [view hierarchy](guide/glossary#view-tree).
|
||||||
@ -118,7 +118,7 @@ export abstract class ViewContainerRef {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the index of a view within the current container.
|
* Returns the index of a view within the current container.
|
||||||
* @parem viewRef The view to query.
|
* @param viewRef The view to query.
|
||||||
* @returns The 0-based index of the view's position in this container,
|
* @returns The 0-based index of the view's position in this container,
|
||||||
* or `-1` if this container doesn't contain the view.
|
* or `-1` if this container doesn't contain the view.
|
||||||
*/
|
*/
|
||||||
|
@ -53,7 +53,7 @@ export abstract class ViewRef extends ChangeDetectorRef {
|
|||||||
* @usageNotes
|
* @usageNotes
|
||||||
*
|
*
|
||||||
* The following template breaks down into two separate `TemplateRef` instances,
|
* The following template breaks down into two separate `TemplateRef` instances,
|
||||||
* an outer one and and an inner one.
|
* an outer one and an inner one.
|
||||||
*
|
*
|
||||||
* ```
|
* ```
|
||||||
* Count: {{items.length}}
|
* Count: {{items.length}}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user