You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think it would be really useful to be able to change the delimiters used by lodash within the this.template() method in a generator. A generator I'm currently working on has client side underscore templates in the output files, as well as a Gruntfile that is trying to use underscore templates for config variables - both are causing collisions. I've tried a solution like this to change the delimiters to <::>, within the generator construction function:
mentioned in this issue: yeoman/yeoman#1235, but that doesn't appear to work, none of the updated delimiter/tags are getting parsed.
I realize I can use my own instance of lodash, or some other templating engine, but it would be really great to be able to use the this.template() method, since it's so much more convenient/useful for generating files from templates...
Perhaps I'm missing something?
The text was updated successfully, but these errors were encountered:
A friend tipped me off to using a double percent in the opening template tag, like <%%= someVar %> which appears to work great for escaping tags during the generator processing. I can't find it in the docs anywhere? Still, may be useful to be able to change template delimiters.
I think it would be really useful to be able to change the delimiters used by lodash within the
this.template()
method in a generator. A generator I'm currently working on has client side underscore templates in the output files, as well as a Gruntfile that is trying to use underscore templates for config variables - both are causing collisions. I've tried a solution like this to change the delimiters to<:
:>
, within the generator construction function:mentioned in this issue: yeoman/yeoman#1235, but that doesn't appear to work, none of the updated delimiter/tags are getting parsed.
I realize I can use my own instance of lodash, or some other templating engine, but it would be really great to be able to use the
this.template()
method, since it's so much more convenient/useful for generating files from templates...Perhaps I'm missing something?
The text was updated successfully, but these errors were encountered: