Learn how to handle tap events.
Video: Step2
If you are building your app from scratch: Step 1 needs to be completed.
OR
If you just want to practice this step: you can start editing Step 1 components in this repo and run
npm run step1
Open app/index.js file in your favorite IDE
import React, {
Text,
View,
TouchableOpacity // <- This line is added
} from 'react-native'; handlePress(){
alert('Pressed!');
}, <TouchableOpacity onPress={this.handlePress}>
<Text style={styles.text}>Let's start coding!!</Text>
</TouchableOpacity>Tap on 'Let's start coding!!' text:
Let's add Navigator component
