Open tima101 opened 1 year ago
getServerSideProps: cannot be used, error: Error: You can not use getInitialProps with getServerSideProps. Please remove getInitialProps.
Error: You can not use getInitialProps with getServerSideProps. Please remove getInitialProps.
The withAuth HOC has to retire in its current form. Its authentication logic can be moved to _app.tsx. Example: https://github.com/async-labs/async/blob/main/app/pages/_app.tsx
withAuth
_app.tsx
See: https://github.com/vercel/next.js/discussions/10925
[x] instructions for serverless v3 (Chapter 9)
getServerSideProps: cannot be used, error:
Error: You can not use getInitialProps with getServerSideProps. Please remove getInitialProps.
The
withAuth
HOC has to retire in its current form. Its authentication logic can be moved to_app.tsx
. Example: https://github.com/async-labs/async/blob/main/app/pages/_app.tsxSee: https://github.com/vercel/next.js/discussions/10925