stack-navigation-web-back-forward-bug

This repo demonstrates how to reproduce the back/forward bug on web.

Steps:

  • Click button which navigates to a route with a parameter, { id: 123 }
  • Click the browser's back button
  • Click the browser's forward button
  • Click the browser's back button

At this point the error occurs. It seems the action that is dispatched has an undefined payload, which is the source of the error.

Logging action Screen Shot 2022-07-12 at 11 12 52 AM

The reset handler assumes that nextState is defined: Screen Shot 2022-07-12 at 11 13 59 AM

Demo

back-forward-issue-demo