Created
September 27, 2017 19:00
-
-
Save kaueDM/0c132c20bb76e1721f81a3a35c39becb 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
//Home.js | |
<Tab heading="TAREFAS" | |
tabStyle={{ backgroundColor: BLUE }} | |
textStyle={{ color: WHITE }} | |
activeTabStyle={{ backgroundColor: BLUE }} | |
activeTextStyle={{ color: WHITE, fontWeight: '900' }} | |
> | |
<TaskList navigate={this.props.navigation.navigate} /> | |
</Tab> | |
//TaskList.js | |
render() { | |
return ( | |
<View> | |
<FlatList | |
style={{ marginTop: 10 }} | |
data={this.props.taskList} | |
keyExtractor={item => item.uid} | |
renderItem={({ item }) => ( | |
<Task item={item} navigate={this.props.navigate} /> | |
)} | |
refreshing={this.props.refreshing} | |
onRefresh={() => this.sync(this.props.taskList, this.props.user.uid)} | |
/> | |
</View> | |
); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment