mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
parent
cdf44c4f91
commit
954fcb9674
|
@ -22,7 +22,7 @@ export default class MyApp extends App {
|
|||
// Get the `locale` and `messages` from the request object on the server.
|
||||
// In the browser, use the same values that the server serialized.
|
||||
const { req } = ctx
|
||||
const { locale, messages } = req || window.__NEXT_DATA__.props.pageProps
|
||||
const { locale, messages } = req || window.__NEXT_DATA__.props
|
||||
|
||||
return { pageProps, locale, messages }
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue