screens/WriteScreen.js
import React from 'react'; import {StyleSheet, View} from 'react-native'; function () { return <View style={styles.block} />; } const styles StyleSheet. ({ block: {}, }); export default WriteScreen;
화면에 대한 컴포넌트를 다 만들었습니다. 이제 하단 탭 내비게이션을 사용하는 MainTab 컴포넌트를 만들어봅시다.
screens/MainTab.js
import React from 'react'; import {createBottomTabNavigator} from '@react-navigation/bottom-tabs'; import FeedsScreen from './FeedsScreen'; import CalendarScreen from './CalendarScreen'; import SearchScreen from './SearchScreen'; const Tab (); function () { return ( <Tab.Navigator> <Tab.Screen name="Feeds" component={FeedsScreen} /> <Tab.Screen name="Calendar" component={CalendarScreen} /> <Tab.Screen name="Search" component={SearchScreen} /> </Tab.Navigator> ); } export default MainTab;