August 2017
Beginner
374 pages
10h 41m
English
In the template code, the server now renders a server/views/index.ejs file instead of the index.html file from the root folder. We will use Embedded JavaScript (EJS) to inject our rendered React components into the HTML template. Later, we will inject the initial Redux store state the same way.
For now, let's inject the rendered components using EJS:
npm install --save ejs
EJS offers the following ways to inject JavaScript code into .ejs template files:
Read now
Unlock full access