Developing a Shared app in ReactJS requires more work than just building a client-rendered app. It also necessitates that you think about your data flow requirements.
There are two components that together make it possible to write a server-rendered app in ReactJS. It can be thought of like an equation:
Pre-rendering components in your server instance + One-way data flow from the server to your components = good app and happy users
In this section, we'll look at the first part of the equation. We'll tackle the data flow issue in the final section of this chapter.
We're going to need a few more packages from npm
to add them to our dependencies section. This is the list of dependencies that we need:
"devDependencies": { "react-transform-catch-errors": "^1.0.1", "react-transform-hmr": "^1.0.1", "redbox-react": "^1.2.0", "webpack-dev-middleware": "^1.4.0", "webpack-hot-middleware": "^2.6.0", "babel-cli": "^6.4.5", "babel-core": "^6.3...