Skip to content

Instantly share code, notes, and snippets.

View luan03's full-sized avatar
🏠
Working from home

Software Development Engineer luan03

🏠
Working from home
View GitHub Profile
@luan03
luan03 / review.md
Created May 2, 2016 02:57 — forked from thomastheyoung/review.md
Javascript Templates Comparison: Hogan, dust, doT, underscore

JavaScript Templates Engines

A quick comparison/ benchmark between Hogan, Dust, doT and underscore

Presentation and Readability

Hogan.js

Developed by Twitter (same team as Bootstrap), use exactly the same syntax as Mustache, but more performant and more stuff available server side.

My name is {{ name }}

/*
Não sabemos o que tem dentro de "e" pode ser uma adição,
remoção ou ambos. O snippet abaixo funciona em todos os casos.
*/
Estado.atualizaEstado = function(e){
//Try to add a state;
try{
if(typeof(e.added.id) !== undefined){
Estado.selected.push(e.added.id);