Created
March 26, 2018 10:47
-
-
Save ho3ein-mola/f8e63db351a4e4886285ef036aa711bd to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import { StatusBar } from "react-native"; | |
import { Container, Button, text, ListItem, Text } from "native-base"; | |
import Expo from "expo"; | |
export default class App extends React.Component { | |
constructor(props) { | |
super(props); | |
this.state = { loading: true }; | |
} | |
async componentWillMount() { | |
await Expo.Font.loadAsync({ | |
Roboto: require("native-base/Fonts/Roboto.ttf"), | |
Roboto_medium: require("native-base/Fonts/Roboto_medium.ttf"), | |
Ionicons: require("@expo/vector-icons/fonts/Ionicons.ttf"), | |
}); | |
this.setState({ loading: false }); | |
} | |
render() { | |
if (this.state.loading) { | |
return <Expo.AppLoading />; | |
} | |
return ( | |
<Container> | |
<StatusBar hidden={true} /> | |
<Button> | |
<Text>Button</Text> | |
</Button> | |
<ListItem /> | |
</Container> | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment