Skip to content

Instantly share code, notes, and snippets.

@ErikAndreas
Last active October 7, 2015 09:22
Show Gist options
  • Save ErikAndreas/9850496 to your computer and use it in GitHub Desktop.
Save ErikAndreas/9850496 to your computer and use it in GitHub Desktop.
PJAX with Ractive.js

Got a repo for this now: https://github.com/ErikAndreas/pjax-ractivejs

Start from/change/extend https://github.com/thybag/PJAX-Standalone with

  • CommonJS format and Browserify
  • Q around Superagent for XHR Promises
  • No need to support more than data-pjax equivalent attribute
  • Same Ractive templates on client as well as server (Ractive is isomorphic)
  • Use Ractive for rendering of client side instead of PJAX "standard" of returning/render full html (also, page title element in response is hideous) and just return data (json) from server, kind of what twitter seem to be doing
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment