We are developing a react native application using Flatlist. Binding data from API service & its working fine. Suppose no data available in service we need to display separate design for that.
We are using "renderEmptyListComponent" for that
sharing the code, please check
<FlatList style={{ backgroundColor: 'white' }}
data={this.state.dataSource}
renderItem={({ item }) => (this.renderMovie(item))}
keyExtractor={item => item.salesID}
renderEmptyListComponent= {this.noItemDisplay}
ItemSeparatorComponent={this.renderSeparator}>
</FlatList>
please guide me how can we do this?