"Slurp" functionality?
johanjordaan opened this issue · comments
Johan commented
Hi. I might have missed a document somewhere, but how do I 'slurp' newlines? I have a template like:
<% for x in xes: %>
<%= x.name %>
<% end %>
Given a list of of xes the template will include extra new lines. I would like the output to be such that there is no newlines.
In EJS I added functionality such that:
<% for x in xes: -%>
<%= x.name %>
<% end -%>
would 'slurp' the newlines. This just makes for neater output.
Does functionality exist to do what I want? If not what is the chances of it being added? I can do it if it makes sense...
Regards
Johan
Paul Young commented
I'm finding that I need this too.