-
-
Notifications
You must be signed in to change notification settings - Fork 5.1k
(0 , _reactNative.TabNavigator) is not a function #812
Copy link
Copy link
Closed
Description
While working through the example in docs, the first step/page (https://reactnavigation.org/docs/intro/) was perfect. Everything worked as advertised (I did have to import button and View which the example didn't)...but page 2 (https://reactnavigation.org/docs/intro/nesting) has got me stumped.
Why is TabNavigator giving that error? Do I need to import something I missed?
My code:
import React from 'react';
import {
AppRegistry,
Text,
View,
Button,
TabNavigator
} from 'react-native';
import { StackNavigator } from 'react-navigation';
import Splash from './app/components/Splash';
import HomeScene from './app/components/HomeScene';
import SettingsScene from './app/components/SettingsScene';
const myapp = StackNavigator({
Home: { screen: HomeScene },
Settings: { screen: SettingsScene },
});
const MainScreenNavigator = TabNavigator({
home: { screen: HomeScene },
settings: { screen: SettingsScene },
});
AppRegistry.registerComponent('myapp', () =>myapp);
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
