Server Side Rendering (SSR) is a famous technique for rendering a normally, in this case, client-side React.js application on the server. This enhances the loading speed of an application.
Below is a simple example of how to create an SSR application with React:
1. Start by creating a new React application:
```
create-react-app ssr-react
```
1. Do all your setup for your modules/routes.
1. Now install two important libraries called `express` and `react-dom/server`.
```
npm install express react react-dom react-router react-router-dom
```
1. Then, create an Express application:
Express is a minimal and flexible Node.js web application framework that provides a robust set of features for web and mobile applications.
```
const server = express()
```
1. Now, set a middleware:
```
server.use(‘/static’, express.static(path.join(__dirname, ‘..’, ‘build’, ‘static’)))
```
1. Create a universal routing and rendering:
```
server.get(‘*’, (req, res) => {
res.write(
`