fir*_*ash 5 javascript reactjs react-native
我在反应原生中使用List View onEndReached组件时遇到了一些麻烦.
渲染代码:
@autobind
_fetchMoreHistory(){
console.log("Fetch more history called");
}
<View style={[styles.Ctr]}>
<ListView dataSource={this.state.txHistorySource}
renderRow={ this._renderRow }
onEndReached ={ this._fetchMoreHistory }
onEndReachedThreshold = {10}/>
</View>
Run Code Online (Sandbox Code Playgroud)
我打开屏幕的那一刻_fetchMoreHistory被调用两次并在onEndReached达到之后正常工作.有人可以帮忙调试吗?
我遇到了同样的问题,搜索了很多,但没有找到任何答案,所以我用一个条件来检查第一个请求是否得到了我再次点火的数据,否则我不会
示例// onEndReached If(condition){拨打电话}
| 归档时间: |
|
| 查看次数: |
4093 次 |
| 最近记录: |