eta
eta copied to clipboard
Passing HTML to templates?
Is there a way to pass HTML data to a template?
For example;
<!-- main.eta-->
<%~ include("template.html", {content: () => { %>
<h1>Content</h1>
<% }}) %>
<!-- template.eta-->
<div id="template">
<%~ it.content() %>
</div>
Alternatively, is there a way to temporarily render to a variable instead of the output?
(related issue #245)
this is the only thing missing to elevate this library into a serious contender for NodeJS SSR
Couldn't agree more! I've been using Eta over the past few months and it's amazing. This is the only thing that it's missing in my opinion