Skip to content

Instantly share code, notes, and snippets.

@wtrocki
Forked from dhoko/templateSettings.js
Created May 23, 2016 20:27
Show Gist options
  • Save wtrocki/eea982defbf1ae1b811642444af78d07 to your computer and use it in GitHub Desktop.
Save wtrocki/eea982defbf1ae1b811642444af78d07 to your computer and use it in GitHub Desktop.
Lodash/underscore custom template settings with {{ }}
_.templateSettings = {
evaluate: /{{+([\s\S]+?)}}/g,
interpolate: /{{([\s\S]+?)}}/g,
escape: /{{-([\s\S]+?)}}/g
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment