-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathApp.js
More file actions
46 lines (33 loc) · 1001 Bytes
/
App.js
File metadata and controls
46 lines (33 loc) · 1001 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import { Home } from './screens/Home';
import AlataRegular from './assets/fonts/Alata-Regular.ttf'
import {useFonts} from 'expo-font'
import { NavigationContainer } from '@react-navigation/native';
import { createNativeStackNavigator } from '@react-navigation/native-stack';
import { Forecast } from './screens/Forecast';
const stack = createNativeStackNavigator();
const navTheme = {
colors:{
background:'transparent'
}
};
export default function App() {
const [isFontLoaded] = useFonts({
"Alata-Regular" : AlataRegular,
});
return (
<NavigationContainer theme={navTheme}>
{isFontLoaded ?
<stack.Navigator
screenOptions={{
headerShown:false,
animation:'fade',
}}
initialRouteName='Home'
>
<stack.Screen name='Home' component={Home}/>
<stack.Screen name='Forecast' component={Forecast} />
</stack.Navigator>
: null}
</NavigationContainer>
);
}