Let us consider screen with Navigation Path as follows:
Scene A > Scene B
From Scene B, pressing Back button '<' will take to Scene A.
+1
This should work:
onBackFunction()
{
console.log("backkkkkkkkkk")
Actions.sceneA()
}
<Scene key="root" >
<Scene key="sceneA" component={SceneA} />
<Scene key="sceneB" onBack={this.onBackFunction()} component={SceneB} />
</Scene>
@Dani93380, I like to pass property from SceneB to SceneA on back button action as like below, but not sure how to call the 'onBackFunction' when I press back button in SceneB
class SceneB extends Component {
render() {...}
onBackFunction(){
Actions.sceneA({myprop:'test'});
}
}
question was asked...issue was closed...no data on solution for original issue... useless forum
Most helpful comment
question was asked...issue was closed...no data on solution for original issue... useless forum