Commit 954fcb96 authored by Ivan Starkov's avatar Ivan Starkov Committed by Tim Neutkens

Fix react-intl example (#4840)

react-intl does not work otherwise
parent cdf44c4f
...@@ -22,7 +22,7 @@ export default class MyApp extends App { ...@@ -22,7 +22,7 @@ export default class MyApp extends App {
// Get the `locale` and `messages` from the request object on the server. // Get the `locale` and `messages` from the request object on the server.
// In the browser, use the same values that the server serialized. // In the browser, use the same values that the server serialized.
const { req } = ctx const { req } = ctx
const { locale, messages } = req || window.__NEXT_DATA__.props.pageProps const { locale, messages } = req || window.__NEXT_DATA__.props
return { pageProps, locale, messages } return { pageProps, locale, messages }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment