Closed DoctorBracewell closed 4 months ago
@DoctorBracewell is attempting to deploy a commit to the Cambridge Community Kitchen Team on Vercel.
A member of the Team first needs to authorize it.
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
cck-volunteer-web-app | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Jun 15, 2024 5:52pm |
2:1 Error: Align from-clause from import statements align-import/align-import
3:1 Error: Align from-clause from import statements align-import/align-import
4:1 Error: Align from-clause from import statements align-import/align-import
5:1 Error: Align from-clause from import statements align-import/align-import
6:1 Error: `react` import should occur before import of `@/components/deliveries-list` import/order```
Received a report of the app getting stuck on the "Oh no! Missing one or more required query parameters." page on firefox on Android 12.
This is triggered when the
router.query
values are undefined, which can still happen after the component is loaded but before hydration. NextJS docs claim that:and
Throttling the network confirms the bug report, but frustratingly the first quoted statement only seems to be sometimes true? Occasionally the "oh no!" message would show up and a few seconds later the app refresh itself with the route data, but occasionally it would stay on the error page without refreshing like the original report.
Regardless, I moved the query values into state and initialised them in a
useEffect
that depends onrouter.query
and therouter.isReady
so that they are explicitly set when the values are available, and testing afterwards confirmed 100% of the time the page refreshed. Hopefully this should fix the issue even for people with crappy connections.