Templating Languages and Engines
Context: frontend-dev-bookmarks / Languages, Protocols, Browser APIs
Template engines are tools to separate program-logic and presentation into two independent parts. This makes the development of both logic and presentation easier, improves flexibility and eases modification and maintenance.
- Marko: Marko is a really fast and lightweight HTML-based templating engine from eBay. Marko runs on Node.js and in the browser and it supports streaming, async rendering and custom tags.
- Mustache: Mustache is a Logic-less template language. There are no if statements, else clauses, or for loops. Instead there are only tags.
- Handlebars.js: Handlebars.js is an extension to the Mustache templating language. Handlebars.js and Mustache are both logicless templating languages that keep the view and the code separated like we all know they should be.
- Hogan.js: Hogan.js is a 3.4k JS templating engine developed at Twitter. It was developed against the mustache test suite.
- Mustache Specification: This document explains the different types of Mustache tags.
- Walrus: Walrus is a templating library inspired by mustache, handlebars, ejs and friends,
but with a couple of important differences in philosophy and style.
- Transparency: Transparency is a minimal template engine for jQuery. It maps JSON objects to DOM elements with zero configuration.
- Weld: Weld binds data to markup, and can generate markup based on your data. There's no special syntax or data reshaping required.