I have a Bottom Tab with a Play Button in the middle, I would like to fire a function instead of load a registered screen.
Right now I have:
children: [
{
component: {
id: 'player'
name: 'navigation.PlayerScreen',
passProps: {
text: 'Player',
}
}
}
],
I´m searching if there´s something like that without the need of a screen:
children: [
{
component: {
id: 'player'
onPress: () => playMusic()
}
}
],
Versions:
Thanks in advance.
This is not possible.
You can do it like this;
If you want to send parameters to the function, you can use passProps. (Remember to update the PlayMusic component)