mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
Add data node to serverState declaration (#3321)
The serverState variable definition did not include the data node, which may cause parsing errors on the client-side. - add data: { } on line 23 within the apollo: { } object
This commit is contained in:
parent
20af8cdabe
commit
f0eacf66ea
|
@ -18,7 +18,11 @@ export default ComposedComponent => {
|
|||
|
||||
static async getInitialProps (ctx) {
|
||||
// Initial serverState with apollo (empty)
|
||||
let serverState = { apollo: { } }
|
||||
let serverState = {
|
||||
apollo: {
|
||||
data: { }
|
||||
}
|
||||
}
|
||||
|
||||
// Evaluate the composed component's getInitialProps()
|
||||
let composedInitialProps = {}
|
||||
|
|
Loading…
Reference in a new issue