Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

renderSection只渲染了一次 #188

Closed
gao520sun opened this issue Oct 15, 2018 · 9 comments
Closed

renderSection只渲染了一次 #188

gao520sun opened this issue Oct 15, 2018 · 9 comments

Comments

@gao520sun
Copy link

<LargeList
style={{flex:1}}
ref={ref => (this._listView = ref)}
reloadData={this.state.dataSource}
numberOfSections={()=>this.state.dataSource.length}
numberOfRowsInSection={section => this.state.dataSource[section].data.length}
heightForCell={()=>74}
heightForSection={()=>20}
renderSection={this.renderSectionHeader.bind(this)}
renderCell={this.renderItem.bind(this)}
renderHeader={this.renderHeader}
/>
4dadc0bf-1a98-4785-a274-fa1eff9c5ab3

3db91db8-4ab8-48d3-a4f3-fa42c771fa46

滑动到底部section不加载P以后的字母

"react-native-largelist": "^1.2.12",

Environment:
OS: macOS High Sierra 10.13.6
Node: 8.11.4
Yarn: 1.9.4
npm: 5.6.0
Watchman: 4.9.0
Xcode: Not Found
Android Studio: 3.1 AI-173.4819257

Packages: (wanted => installed)
react: 16.2.0 => 16.2.0
react-native: 0.53.0 => 0.53.0

@ATShiTou
Copy link
Collaborator

ATShiTou commented Oct 15, 2018

你这种情况需要加大numberOfSectionPoolSize,具体可以看之前的issues #66

升级成V2吧,V1没维护了, V2不需要考虑这个问题,使用更简单,只是没做左右滑动的功能

@gao520sun
Copy link
Author

npm install react-native-largelist --save 这样升级不到v2

@ATShiTou
Copy link
Collaborator

文档啊 ! V2为了避免很多人升级出问题,我新建了一个库 react-native-largelist-v2

@gao520sun
Copy link
Author

之前你的文档没有打开 现在可以了 麻烦你了 我关闭这问题了

@gao520sun
Copy link
Author

安装react-native-gesture-handler 报错 Unhandled JS Exception: undefined is not an object (evaluating 'RNGestureHandlerModule.State') 你这边有解决方案吗?

@gao520sun gao520sun reopened this Oct 15, 2018
@ATShiTou
Copy link
Collaborator

没有链接原声库,基本的东西!

@bolan9999
Copy link
Owner

按文档来

@gao520sun
Copy link
Author

81b021cc-da17-4158-ad89-a1e0968ee3e8
react-native link react-native-gesture-handler 这步骤做了

@ATShiTou
Copy link
Collaborator

  1. 检查链接没有,在Build Phases里面查看
  2. 是不是没重新编译运行

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants