Update UsingAListView.md - Add flex:1 to View

Summary:
Add flex:1 to View's style prop, so the ListView can be scrolled.
Closes https://github.com/facebook/react-native/pull/10304

Differential Revision: D3993754

Pulled By: JoelMarcey

fbshipit-source-id: 23d73b23310a5b39dea4cf3c6f3af0bf2901480f
This commit is contained in:
ronhe 2016-10-09 10:58:30 -07:00 committed by Facebook Github Bot
parent 770091f3c1
commit 79e1eacc18
1 changed files with 1 additions and 1 deletions

View File

@ -35,7 +35,7 @@ class ListViewBasics extends Component {
}
render() {
return (
<View style={{paddingTop: 22}}>
<View style={{flex: 1, paddingTop: 22}}>
<ListView
dataSource={this.state.dataSource}
renderRow={(rowData) => <Text>{rowData}</Text>}