React Redux-Saga server-side rendering helper
"Under the hood" for React server-side rendering. See usage example there - https://github.com/gzoreslav/react-redux-saga-universal-application
This package hide server and client sides rendering mechanism. Built using official recommendations from redux and react router v4
Installation
> npm i react-redux-saga-server-side-render-helper --save
Examples
client.js
;; ;
server.js
;;; const handleRender = ; const app = ;const port = 3030;app;app;app;
config.js
;;;;; const appName = 'My Application'; const appData = routes rootReducer rootSaga App; const pageConfig = appName `` appData; const reactConfig = next: appData; const apiConfig = next: appData; const appConfig = next: appData;
What new?
v.2.x.x
- separated server, client and story features into separate files for better support
- fixed routing params
Credits
- https://redux.js.org/docs/recipes/ServerRendering.html
- https://reacttraining.com/react-router/web/guides/server-rendering
- https://scotch.io/tutorials/build-a-media-library-with-react-redux-and-redux-saga-part-1
- https://scotch.io/tutorials/build-a-media-library-with-react-redux-and-redux-saga-part-2
Sending Feedback
I am always open to your feedback.
License
This software is distributed under an MIT licence.
Copyright 2017 © Zoreslav Goral