clarify the picker onValueChange

Summary:
In the current docs, it's not quite clear, at the first sight, what the `lang` parameter passed to `onValueChange` is. This makes it obvious.
Closes https://github.com/facebook/react-native/pull/13617

Differential Revision: D4969592

Pulled By: javache

fbshipit-source-id: e94bedefebbe19d838d010f0c79d9a76743a4341
This commit is contained in:
Vojtech Novak 2017-04-28 03:59:07 -07:00 committed by Facebook Github Bot
parent 00a0343a6d
commit 7888c06a7b
1 changed files with 1 additions and 1 deletions

View File

@ -77,7 +77,7 @@ class PickerItem extends React.Component {
*
* <Picker
* selectedValue={this.state.language}
* onValueChange={(lang) => this.setState({language: lang})}>
* onValueChange={(itemValue, itemIndex) => this.setState({language: itemValue})}>
* <Picker.Item label="Java" value="java" />
* <Picker.Item label="JavaScript" value="js" />
* </Picker>