WinJS.UI.Pages.render function
Creates a PageControl from the specified Uniform Resource Identifier (URI) and inserts it inside the specified Document Object Model (DOM) element.
Syntax
WinJS.UI.Pages.render(uri, element, options, parentedPromise).done( /* Your success and error handlers */ );
Parameters
uri
Type: StringThe URI for the content that defines the page.
element
Type: DOMElementThe DOM element in which the PageControl is created.
options [optional]
Type: ObjectAn object that contains one or more property/value pairs to apply to the new PageControl. How these property/value pairs are used (or not used) depends on the implementation of that particular PageControl.
parentedPromise [optional]
Type: Promise**A Promise that is fulfilled when rendering of the new PageControl is complete and its content becomes the child of element.
Return value
Type: Promise**
If asynchronous processing is necessary, a promise that is fulfilled when rendering is complete. Otherwise, nothing.
Requirements
Minimum WinJS version |
WinJS 1.0 |
Namespace |
WinJS.UI.Pages |
See also
For developers
Your first app - Part 3: PageControl objects and navigation
Quickstart: Using single-page navigation
Quickstart: Adding Page controls
Adding a Page control item template
Navigation and navigation history sample
For designers