WidgetTemplate
Namespace: Wisej.Web.Ext.Webix
Assembly: Wisej.Web.Ext.Webix (4.1.0.0)
Represents a Webix template.
- C#
- VB.NET
public class WidgetTemplate
Public Class WidgetTemplate
Templates in the Webix library are either plain global JavaScript functions, or HTML snippets using their template syntax.
Constructors
WidgetTemplate()
Initializes a new instance of WidgetTemplate.
Properties
Id
String: Returns or sets the identifier of the WidgetTemplate. It becomes the id of the script element that holds the template in the page. (Default: "")
Template
String: Returns or sets the content of the WidgetTemplate: an HTML snippet that uses the Webix template syntax. (Default: "")
Example:
The following example defines a template that renders the name and email fields of a data item.
var template = new wxBase.WidgetTemplate
{
Id = "personTemplate",
Template = "<b>#name#</b><br/>#email#"
};
Type
String: Returns or sets the type of the template. It becomes the type attribute of the script element that holds the template. Use "text/x-jsrender" for HTML templates. (Default: "text/x-jsrender")