Created
March 24, 2020 22:03
-
-
Save DeVoresyah/869767547ced1373cb0354e36a98b594 to your computer and use it in GitHub Desktop.
[Draft Example] React Native Style Framework
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, { Component } from 'react'; | |
import { | |
View, | |
Text, | |
StatusBar, | |
TouchableOpacity | |
} from 'react-native'; | |
import styles from './styles' | |
import colors from './styles/data/colors' | |
class App extends Component { | |
constructor(props) { | |
super(props); | |
} | |
render() { | |
return ( | |
<View style={styles([ | |
"flex", | |
"items-center", | |
"justify-center" | |
])}> | |
<StatusBar backgroundColor={colors["red500"]} barStyle="light-content" /> | |
<Text style={styles([ | |
"text-6xl", | |
"font-medium", | |
"text-center", | |
"mb-5" | |
])}>Welcome to MobCSX!</Text> | |
<TouchableOpacity | |
activeOpacity={0.8} | |
style={styles([ | |
"bg-red-500", | |
"rounded", | |
"p-2", | |
"px-4" | |
])}> | |
<Text style={styles([ | |
"text-white" | |
])}>Click Here!</Text> | |
</TouchableOpacity> | |
</View> | |
) | |
} | |
} | |
export default App; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment