-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New polyfill to fix PubSub for SSR breaks checks for SSR. #640
Comments
Hi @cgarvis, Thank you for reporting this bug. We will fix it soon. |
Encountered the same problem. @cgarvis Have you rolled back to a previous version? or you are still unable to use aws-amplify with nextjs SSR? |
Also experiencing this issue with the latest versions of amplify and nextjs.
Quick question. If amplify adds a location property with an empty object to the polyfill here, nextjs will still error due to href not being defined. What's the solution there? Is it something that amplify should handle or nextjs in the way they are getting the url here. |
Add location and href props to polyfill - issue #640
This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs. Looking for a help forum? We recommend joining the Amplify Community Discord server |
Versions:
aws-amplify@0.2.15
next.js@5.0.1
What is the current behavior?
When using the latest amplify code with polyfill, it doesn't polyfill the
window
object fully so it breaks other SSR checks liked here: https://github.com/zeit/next.js/blob/085b2f806afd4d16e6f4754cce62e88d7bd47518/lib/router/router.js#L45-L50 which ingetUrl
is looking to thehref
onlocation
which hasn't been polyfilled.What is the expected behavior?
Set
location
to empty object.The text was updated successfully, but these errors were encountered: