Search code examples
reactjsreact-nativereact-native-router-flux

How can I reset a page without resetting the router stack?


I need to reset a page when I go to it. But I don't want to reset the router stack so that I can still use pop() to go to the previous page.

I have tried with Actions.pageName({type: ''}):

replace But it resets the router stack.

reset Also resets router stack.

refresh Doesn't even load the page.


Solution

  • Try Actions.pop({refresh: {...propsToSetOnPreviousScene}})