Example from css-tricks, adapted for node.
$ git clone https://github.com/nichoth/history-example.git
$ cd history-example
$ npm install
$ npm run build
$ node server.js
Checkout pjax โ uses a special request header, so the server can decide whether to send full pages or partials based on the header.
- Use
virtual-dom
for all rendering - Same rendering code on client and server
- Server serves full pages โ works without any JS
- use
vdom-virtualize
to start the client side rendering.