consolidate
Advanced tools
Comparing version 0.8.0 to 0.9.0
0.9.0 / 2013-03-28 | ||
================== | ||
* dust-helpers support, latest version of dust | ||
* Re-add doT - global leaks fixed | ||
* improving templayed support | ||
0.8.0 / 2013-01-23 | ||
@@ -3,0 +10,0 @@ ================== |
@@ -199,3 +199,7 @@ /*! | ||
} catch (err) { | ||
engine = requires.dust = require('dustjs-linkedin'); | ||
try { | ||
engine = requires.dust = require('dustjs-helpers'); | ||
} catch (err) { | ||
engine = requires.dust = require('dustjs-linkedin'); | ||
} | ||
} | ||
@@ -464,4 +468,4 @@ } | ||
try { | ||
var tmpl = cache(options) || cache(options, engine(str)(options)); | ||
fn(null, tmpl); | ||
var tmpl = cache(options) || cache(options, engine(str)); | ||
fn(null, tmpl(options)); | ||
} catch (err) { | ||
@@ -678,2 +682,22 @@ fn(err); | ||
} | ||
} | ||
}; | ||
/** | ||
* doT support. | ||
*/ | ||
exports.dot = fromStringRenderer('dot'); | ||
/** | ||
* doT string support. | ||
*/ | ||
exports.dot.render = function (str, options, fn) { | ||
var engine = requires.dot || (requires.dot = require('dot')); | ||
try { | ||
var tmpl = cache(options) || cache(options, engine.compile(str)); | ||
fn(null, tmpl(options)); | ||
} catch (err) { | ||
fn(err); | ||
} | ||
}; |
{ | ||
"name": "consolidate", | ||
"version": "0.8.0", | ||
"version": "0.9.0", | ||
"description": "Template engine consolidation library", | ||
@@ -26,3 +26,4 @@ "keywords": [ | ||
"dust": "0.3.0", | ||
"dustjs-linkedin": "0.4.0", | ||
"dustjs-linkedin": "1.2", | ||
"dustjs-helpers":"1.1.1", | ||
"handlebars": "1.0.7", | ||
@@ -37,4 +38,5 @@ "underscore": "1.3.3", | ||
"toffee": "0.0.52", | ||
"atpl": ">=0.5.5", | ||
"templayed": ">=0.2.3" | ||
"atpl": ">=0.5.5", | ||
"templayed": ">=0.2.3", | ||
"dot": "1.0.1" | ||
}, | ||
@@ -41,0 +43,0 @@ "main": "index", |
22068
574
28