Hi,
I'am planning on using Rhino as a replacement for JSP, soo I've hacked
the parser adding a optional feature to enable a similar syntax:
-- cut --
%><h1>Title</h1>
<ul>
<% for (var i = 1; i <= 10; i++) { %>
<li>Item #<%= i %></li>
<% } %>
</ul>
-- cut --
Now some questions:
1. Is anyone else interested is such a feature?
2. Would such a feature, properly implemented, ever be accepted to the
main trunk of the Rhino source?
3. If yes. Any tips on how to correctly implement this? I've now just
added an additional token '%>template text<%', the parser then creates
AST nodes to call a "print" function with the template text and '<%='
expression as arguments. As said, currently a quick hack.
/ henrik
_______________________________________________
dev-tech-js-engine-rhino mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-js-engine-rhino