Closed yoshuawuyts closed 9 years ago
Guess this would be shorthand for https://github.com/shama/base-element/blob/master/examples/server-side.js#L24-L31. Thinking the interface would look something like:
const str = el.toString(['This is', 'the initial', 'content'])
+1 That's a good idea. Because then we could perform a render first too in case element
hasn't been created.
When rendering on the server it can be neat to implement a
.toString()
function (or equivalent) to render components tohtml
. I'm not sure what the tradeoffs are; but I think it's feasible to implement for every component. Thanks!See Also