Super fast rendering, easy to pick up, no DOM nor jQuery dependency. That’s JsRender. Check out this month’s Client Insight column where I cover the basics of JsRender. And be on the lookout for my new full length course on JsRender, coming to Pluralsight in May 2012.
JsRender is the successor to jQuery Templates created by Boris Moore. It brings a new templating library to HTML5 development that has a code-less tag syntax, high performance, no dependency on jQuery nor a DOM, supports creating custom functions, and uses pure string-based rendering.
So instead of writing code like this:
var i = 1;
$(my.vm.movies).each(function () {
var movie = this;
$("#movieContainer1").append(
"<div>" + i++ + ": " + movie.name + " ("
+ movie.releaseYear + ")</div>");
});
you can write code like this:
<div>
: ()
</div>