mirror of
https://github.com/vale981/Vulcan
synced 2025-03-06 18:11:40 -05:00
14 lines
No EOL
583 B
JavaScript
14 lines
No EOL
583 B
JavaScript
import { _ } from 'meteor/underscore';
|
|
|
|
// As identified in issue #9149, when an application overrides the default
|
|
// _.template settings using _.templateSettings, those new settings are
|
|
// used anywhere _.template is used, including within the
|
|
// boilerplate-generator. To handle this, _.template settings that have
|
|
// been verified to work are overridden here on each _.template call.
|
|
export default function template(text) {
|
|
return _.template(text, null, {
|
|
evaluate : /<%([\s\S]+?)%>/g,
|
|
interpolate : /<%=([\s\S]+?)%>/g,
|
|
escape : /<%-([\s\S]+?)%>/g,
|
|
});
|
|
}; |