公告
财富商城
积分规则
提问
发文
2020-06-09 05:01发布
兄弟一词,经得起流年.
I want to horizontally scroll some part of a ListView in React Native.
How can I fix the position of first column and make other column horizontally scrollable?
The renderRow of ListView should have a Text followed by a horizontal ScrollView.
<ListView dataSource={this.state.dataSource} renderRow={this.renderRow} /> renderRow (rowData) { return ( <View> <Text>rowData.field1</Text> <ScrollView horizontal={true}> <Text>rowData.field2</Text> <Text>rowData.field3</Text> <Text>rowData.field4</Text> </ScrollView> </View> }
Note the horizontal=true prop in ScrollView which will make it happen.
最多设置5个标签!
The renderRow of ListView should have a Text followed by a horizontal ScrollView.
Note the horizontal=true prop in ScrollView which will make it happen.