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

Warning:Each child in an array or iterator should have a unique "key" prop. #25

Open
agilests opened this issue Nov 27, 2017 · 2 comments

Comments

@agilests
Copy link

react-native-shadow:^1.2.1
react-native-svg:^6.0.0

Report this Warning:Each child in an array or iterator should have a unique "key" prop.
in Svg(at BorderShadow.js:35)

@franj0
Copy link

franj0 commented Jun 28, 2018

just add key prop to parent element inside map arrow function

[1,2,3,4].map((item, key) => {
return
})

@changyu2hao
Copy link

If I only have one component, how can I add the key?
like this:
{[
<TextInput
style={searchSuggestionsStyles.inputStyle}
underlineColorAndroid="transparent"
placeholder={'Enter a subject, course or tutor name...'}
placeholderTextColor="#B0ACAC"
spellCheck={false}
returnKeyType="search"
/>]}

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