Create a gist now

Instantly share code, notes, and snippets.

Embed
What would you like to do?
RN-LFVL-7 - Replacing renderFooter with ListFooterComponent
export default class Application extends Component {
...
render() {
if (this.state.isLoading) {
...
} else {
return (
<FlatList
...
ListFooterComponent={() => { // replaces renderFooter={() => {
return (
this.state.isLoadingMore &&
<View style={{ flex: 1, padding: 10 }}>
<ActivityIndicator size="small" />
</View>
);
}}
...
/>
);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment