we keep control over our app architecture; we can integrate Redux
simply by following its SSR docs.
We recommend to be familiar with the following before proceeding.
On a high-level, the SSR integration works like this:
- We set the initial state of the store on the server-side. (We need to do it on the server-side if we want the initial state to be rendered to HTML.)
- We make the initial state available as
- We make
pageContext.initialStoreState available on the browser-side by adding
- We initialize the store on the browser-side using
See the repository's /examples/redux/.