Advertisement
Guest User

Untitled

a guest
Mar 22nd, 2018
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. import React from 'react';
  2. import { TouchableOpacity, StyleSheet, Text, View } from 'react-native';
  3.  
  4. export default class App extends React.Component {
  5. onButtonPress = () => {}
  6. render() {
  7. return (
  8. <View style={styles.container}>
  9. <TouchableOpacity
  10. style={styles.button}
  11. onPress={this.onButtonPress}
  12. >
  13. <Text style={styles.buttonText}>Button</Text>
  14. </TouchableOpacity>
  15. </View>
  16. );
  17. }
  18. }
  19.  
  20. const styles = StyleSheet.create({
  21. container: {
  22. flex: 1,
  23. backgroundColor: '#fff',
  24. alignItems: 'center',
  25. justifyContent: 'center',
  26. },
  27. button: {
  28. backgroundColor: '#33ccff',
  29. borderRadius: 100,
  30. padding: 30
  31. },
  32. buttonText: {
  33. color:'#fff',
  34. fontSize: 30
  35. }
  36. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement