smfoote / tornado

HTML templates with asynchronous rendering, built with JavaScript.
http://smfoote.github.io/tornado/
Apache License 2.0
8 stars 3 forks source link

Server Side Rendering #63

Open smfoote opened 9 years ago

smfoote commented 9 years ago

Tornado templates should be able to render on the server with Node. There are Node implementations of the DOM API (e.g. simple-dom) that should get us most of the way there, but there are still a few things lacking.

smfoote commented 9 years ago

The new version of the compiler allows us to compile to whatever we want (or compile to one language in different ways). We should consider this as a part of our SSR discussion.

smfoote commented 8 years ago

Although simple-dom doesn't support innerHTML and outerHTML, it does have a method for turning an HTML Node into a string: HTMLSerializer#serialize.

An example of how to implement innerHTML using serializer can be found in the Riot project

smfoote commented 8 years ago

A working version of SSR can be found at #102