next-redux-wrapper TypeError: nextCallback is not a function error in wrapper.getServerSideProps

The signature for the function passed to wrapper.getServerSideProps has changed in next-redux-wrapper v7.x.

Replace the following.

export const getServerSideProps = wrapper.getServerSideProps(async ({req, store}) => {
     // Code here
})

With the right signature.

export const getServerSideProps = wrapper.getServerSideProps((store) => async ({ req }) => {
     // Code here
})

Leave a Comment

deneme bonusu veren sitelerbahis casino