View (Constructor) Summary Constructs a view and binds it to the specified Handlebars template. Usage public View(string template) Parameters template A Handlebars template. Description Constructs a view and binds it to the specified Handlebars template. Examples Basic Usage 1234567891011121314151617181920import Altitude.Frontend; external jQuery, $; // Import jQuery (optional) class Contact : View{ // Construct a view based on the specified template Contact() { super( """ <div class="contact">{{firstName}} {{lastName}}</div> """ ); } // Describe how the HTML gets rendered once the model changes override renderTemplate(string html) { $("#contact").html(html); }} Share HTML | BBCode | Direct Link