> Is there a paradigm/language that allows you to write the same templates for both the server side and SPA view?
That's the main motivation behind my web framework Sandro. It is just an experiment, but I do just that!
See https://bitbucket.org/aurelito/sandro and https://bitbucket.org/aurelito/sandro-lib
It uses rhino and domino to render server side using the DOM API. I am busy with work that pays my bills, but I would love if I were able to work full-time in it ;).