A basic starting point for using server-side rendering with ReasonReact via Razzle.
Far from refined. Used as a basis to learn ReasonML and POC for server side rendering and code-splitting with ReasonReact
- ReasonReact
- Razzle for easy server-side rendering
- Reason-Apollo
- React Helmet Async bindings
- Use install dependencies:
yarn
- For dev mode without ssr run
yarn dev
ornpm run dev
, open browser, the app should be running at: http://localhost:3000. - To build run:
yarn build
ornpm run build
- To build and run use:
yarn build
ornpm run build
followed byyarn start
ornpm start
.
- Add "CSS-In-Reason" library. Either bs-css or bs-react-fela.
- Add Workbox
Server-side rendering with Reason-Apollo doesn't actually work. Queries don't execute on the server.