@microsoft/fast-element > ViewTemplate > render
ViewTemplate.render() method
Creates an HTMLView from this template, binds it to the source, and then appends it to the host.
Signature:
render(source: TSource, host: Node, hostBindingTarget?: Element): HTMLView<TSource, TParent>;
Parameters
|
Parameter |
Type |
Description |
|---|---|---|
|
source |
TSource |
The data source to bind the template to. |
|
host |
Node |
The Element where the template will be rendered. |
|
hostBindingTarget |
Element |
(Optional) An HTML element to target the host bindings at if different from the host that the template is being attached to. |
Returns:
HTMLView<TSource, TParent>