Created
April 18, 2018 14:52
-
-
Save lmiller1990/04c46014a95be0499b21ec67a3c4d7fd 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
// ... imports and stylesheet | |
export default class Events extends React.Component { | |
constructor() { | |
super() | |
this.state = { count: 0 } | |
} | |
render() { | |
return ( | |
<View | |
onMove={() => this.setState({ count: this.state.count + 1 })} | |
style={styles.view} | |
> | |
<Text> | |
{this.state.count} | |
</Text> | |
</View> | |
); | |
} | |
}; | |
AppRegistry.registerComponent('Events', () => Events); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment