jTemplates is a template plugin written for the jQuery.
jTemplate is a template engine used in conjunction with the jQuery library.
It's current features include:
- 100% in JavaScript
- precompilator
- Support JSON
- Work with Ajax
- Allow to use JavaScript code inside template
- Allow to build cascading templates
- Allow to define parameters in templates
- Live Refresh! - automatic update content from server
Template Example:
var data = { "header": "Header Text", "text": "Hello World!" };
//Where result is the template target
$("#result").setTemplate(
'<h3>{$T.header}</h3>' +
'<p>{$T.text}<p>');
$("#result").processTemplate(data);
Works with:
- Firefox 1.5+
- Internet Explorer 6+
- Opera 9+
- Safari 3+
- Google Chrome
- modern mobile browsers (iPhone, Android, Windows Phone)