Created
January 19, 2019 02:02
-
-
Save BrodaNoel/2baae3df3fd01e9ce462fcc0360f084e to your computer and use it in GitHub Desktop.
This file contains 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 { View, TouchableOpacity } from 'react-native'; | |
import duix from 'duix'; | |
class Login extends React.Component { | |
onLoginClick = () => { | |
// here you do something to login the user | |
// ... | |
// then redirect to the Home page | |
duix.set('currentPage', 'Home'); | |
}; | |
render() { | |
return ( | |
<View style={[{ flex: 1 }]}> | |
<TouchableOpacity onPress={this.onLoginClick}> | |
<View> | |
<Text>Press here to simulate a LogIn</Text> | |
</View> | |
</TouchableOpacity> | |
</View> | |
); | |
} | |
} | |
export default Login; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment