Thursday, April 05, 2007

javascript templating library


<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"></meta>
<script type="text/javascript"
src="http://mjtemplate.org/dist/latest/mjt.js"></script>
</head>
<body onload="mjt.run('top')">
<div id="top" style="display:none">
The group behind Freebase have released MTJ, the templating library they created for their own use:

Mjt makes it very simple to take data from a web service and format it in a browser, with no server support. The templates are hosted and delivered as static HTML, and they are compiled and applied entirely in Javascript.

Mjt is particularly useful with services that return JSON values and accept a callback= parameter, such as the Freebase service and the Yahoo JSON API. With these services you can use mjt to build "mash-ups" that incorporate data from services on multiple hosts.
<!-- the template lives inside this div element => running mjt version 0.3 -->
running mjt version $mjt.VERSION

</div>
</body></html>

No comments :