1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
next.js/examples/with-react-intl/pages
Brian Beck 50662c6a83 Fix initialNow in react-intl example (#5867)
The `initialNow` prop is used to avoid content mismatches when Universal/SSR apps render date values using components like `<FormattedRelative>`.

If this value is created in `render()`, then the server will generate it and then the client will also generate it during hydration / initial render, resulting in two different values and content mismatches like:

> Warning: Text content did not match. Server: "in 1,741,545 seconds" Client: "in 1,741,543 seconds"

If the value is instead generated in `getInitialProps`, then the client's initial rendering will match because it will use the same value sent down by the server.
2018-12-12 11:02:36 +01:00
..
_app.js Fix initialNow in react-intl example (#5867) 2018-12-12 11:02:36 +01:00
_document.js Add Intl API polyfill in with-react-intl example (#2283) 2017-06-16 12:30:35 +02:00
about.js update with-react-intl example (#4817) 2018-07-22 01:37:25 +02:00
index.js Update with-react-intl example (#4825) 2018-07-24 00:43:57 +02:00