Created
May 21, 2018 14:15
-
-
Save lst15/87222eb5603f18b5eb0a25059dca2782 to your computer and use it in GitHub Desktop.
Tentando navigar
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
| /** | |
| * Sample React Native App | |
| * https://github.com/facebook/react-native | |
| * @flow | |
| */ | |
| import React, { Component } from 'react'; | |
| import { | |
| Text, | |
| View, | |
| Button | |
| } from 'react-native'; | |
| import {StackNavigator} from 'react-navigation'; | |
| import Scan from './tela2' | |
| const routes = StackNavigator({ | |
| tela2 : Scan | |
| }) | |
| export default class App extends Component { | |
| static navigationOptions = { | |
| title: 'Welcome', | |
| }; | |
| render() { | |
| const { navigate } = this.props.navigation; | |
| return ( | |
| <Button | |
| title="Go to Jane's profile" | |
| onPress={() => | |
| navigate('tela2') | |
| } | |
| /> | |
| ); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment