Example of Isomorphic React Application written in PureScript
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
src/Jam
static
test
.gitignore
LICENSE.md
README.md
bower.json
gulpfile.js
package.json
start.js

README.md

Example of Isomorphic React Application written in PureScript

It's using cofree-react-router for routing, the server is written using the hyper library.

In the frontend app the top most component rendered as:

createElement browserRouterClass {router, notFound: Nothing} []

where browserRouterClass comes from cofree-react-router, on the backend we can render the app using:

runRouter url router

since this is how browserRouterClass renders (with exception of routes that where not found). This is fine for react since it compares the html content (using a modified version of adler32, if you wish to check the react code it is here ).

State

The state is manged by purescript-redox which is similar to redux, but the dsl - interpreter pair is a free monad paired with cofree comonad rather than redux actions with redux reducer.