Skip to content

Instantly share code, notes, and snippets.

@matthewmueller
Created March 25, 2011 01:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save matthewmueller/886228 to your computer and use it in GitHub Desktop.
Save matthewmueller/886228 to your computer and use it in GitHub Desktop.
Javascript: Use underscore templating to parse HTML files in Express
// Express with Underscore templating
app.register('.html', {
compile : function(str, options) {
return function(locals) {
return _.template(str, locals);
};
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment