-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathApp.js
More file actions
48 lines (40 loc) · 1.13 KB
/
App.js
File metadata and controls
48 lines (40 loc) · 1.13 KB
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
47
48
import { StatusBar } from "expo-status-bar";
import React from "react";
import { Text } from "native-base";
import { LogBox } from "react-native";
// native base requirements
import { AppLoading } from "expo";
import * as Font from "expo-font";
import { Ionicons } from "@expo/vector-icons";
// Navigator
import Navigator from "./routes/HomeStack";
export default class App extends React.Component {
constructor(props) {
super(props);
this.state = {
isReady: false,
};
}
async componentDidMount() {
await Font.loadAsync({
Roboto: require("native-base/Fonts/Roboto.ttf"),
Roboto_medium: require("native-base/Fonts/Roboto_medium.ttf"),
...Ionicons.font,
});
this.setState({ isReady: true });
}
render() {
// LogBox.ignoreLogs(["VirtualizedLists should never be nested"]);
// LogBox.ignoreLogs([
// "VirtualizedList: missing keys for items, make sure to specify a key or id property on each item or provide a custom keyExtractor.",
// ]);
if (!this.state.isReady) {
return <Text>Loading...</Text>;
}
return (
<>
<Navigator />
</>
);
}
}