react: "16.11.0",
react-native: "0.62.2",
react-native-navigation: "^6.4.0",
react-native-tab-view: "^2.14.0",
I'm trying to use react-native-tab-view with react-native-navigation V3.
So far I able to use a registered-component in this way:
import EventsScreen from './EventsScreen';
function registerScreens()
{
...
Navigation.registerComponent('com.events.EventsScreen', () => gestureHandlerRootHOC(EventsScreen));
...
}
In the React.Component
page where I wants the tab-view:
import EventsScreen from './EventsScreen';
let renderScene = SceneMap({
first: EventsScreen,
second: AddEventScreen });
The above way works, but I can not pass any props to the EventsScreen. I was more likely to expect a design something like,
{
component: 'com.events.EventsScreen',
passProps: { .. }
}
Following does not work if I tried in this way:
let renderScene = SceneMap({
first: 'com.events.EventsScreen',
second: 'com.events.AddEventScreen' });
What is the correct way to provide a React.Component
view to SceneMap
with props?