ejs
ejs copied to clipboard
";" in <%- %> or <%= %> creates a SyntaxError
When using a regular ";" within <%- %> or <%= %> block ejs throws a SyntaxError. As this is valid JS Syntax it should not.
Failing example:
<%- "foo"; %>
Working example:
<%- "foo" %>
First, it should throw an error, as <%-
and <%=
are supposed to be JavaScript expressions not statements.
Second, in EJS v2 (mde/ejs) we have loosened this requirement. In my fork of @tj's EJS with EJS v2 features but EJS v1 performance (TimothyGu/ejs) I have also loosened the requirement.