Closed zcuric closed 5 months ago
Thanks, this PR fixes the useRemember
's bug #1766
I'll close this one once #1784 is merged.
@zcuric Yes, it fixes the issue.
Thank you but will close this one in favour of https://github.com/inertiajs/inertia/pull/1784
@driesvints thank you! 🖖🏻
This PR:
In certain scenarios when the user is moving back and forth with the browser page data is lost and
setPage
tries to resolve an empty component, resulting in an undefined error being seen. Multiple Interia users have reported this issue and we are experiencing it in our project also (see attached image). Error is thrown fromlaravel-vite-plugin
Intertia helperresolvePageComponent
, but in general, this shouldn't happen if there is no page.page
object should be typed more strictly, but that is larger effort.Also, when debugging I've also noticed that
visitId
is always an empty object, so the if statement inthen
always gets executed because{} === {}
. I've never seen thatvisitId
had any meaningful value.