Tmplits

Tmplits is a framework for building HMI’s using the Handlebars template system. Tmplits manages loading assets and making them available as Partials to use throughout the HMI. This allows mixing standard HTML with a powerful template system, out of the box.


You can define content as a Partial:

MyCustomView.handlebars

<div>Hello World</div>

Anywhere you want to use a Partial, use the syntax:

{{> MyCustomView}}

In addition to Handlebars Partials, Tmplits implements a JavaScript-based user control system that allows even more flexibility in building controls.

To define a custom control:

//Any functions that is prefixed with tmplit
//  is made available to your handlebars
function TmplitHello(context, args){
    //Generate your custom components!
    return `<div>Hello ${context[0]}</div>`
}

To use your custom controls you call them with the tmplit syntax:

{{tmplit 'Hello' 'world'}}

Tmplits also contains many ready-to-use HMI components, with little to no configuration required. The library and template system allows for flexible and fast HMI development.

For more information about Handlebars, please reference their API documentation

Overview