Fix warnings generated by Elements Inspector

Summary:
public

When using dev menu - elements inspector, a yellow box appears
with React warning regarding missing key prop in elements array.
This commit fixes this issue.

Reviewed By: martinbigio

Differential Revision: D2835332

fb-gh-sync-id: 3fcb37dfb6bdcff3788963b36416b7da190b9a84
This commit is contained in:
Alex Kotliarskyi 2016-01-25 18:36:10 -08:00 committed by facebook-github-bot-0
parent 91fe9158c9
commit c1aed7ba41
1 changed files with 6 additions and 1 deletions

View File

@ -47,6 +47,7 @@ var ElementProperties = React.createClass({
this.props.hierarchy,
(item, i) => (
<TouchableHighlight
key={'item-' + i}
style={[styles.breadItem, i === selection && styles.selected]}
onPress={() => this.props.setSelection(i)}>
<Text style={styles.breadItemText}>
@ -54,7 +55,11 @@ var ElementProperties = React.createClass({
</Text>
</TouchableHighlight>
),
() => <Text style={styles.breadSep}>&#9656;</Text>
(i) => (
<Text key={'sep-' + i} style={styles.breadSep}>
&#9656;
</Text>
)
)}
</View>
<View style={styles.row}>