Open DylanPiercey opened 8 years ago
Hi,
I have plans to implement server rendering, via separation of compilers: DOM compiler and string compiler. There well be different compiled javascripts for string compiler. But now i don't know how to best integrate this in node.js.
Randomly stumbled on this library - it looks awesome. One thing that seems missing is the ability to initially render on the server side.
Even internally using something like https://github.com/krisselden/simple-dom would help.
Ideally there would be a "monkberry-server" compiler that rendered a string instead of dom for isomorphic apps though.
However I think the trickiest bit is "bootstrapping" existing dom so that you aren't destroying inputs and such when the js takes over.
If this was to be done I think a node-js "require hook" similar to babel and coffee-script would be handy as well to allow for isomorphic code when paired with
monkberryify
.Something like:
Great work with this, although I haven't tested it out yet it looks very promising.