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 a list should have a unique "key" prop. Check the render method of Picker. #729

Open
Akshaybagai52 opened this issue Nov 6, 2023 · 1 comment

Comments

@Akshaybagai52
Copy link

I'm getting this warning in only that picker where I'm using this as data :-
[
{"label": "123 Main St, Dummy City", "value": "123 Main St, Dummy City"},
{"label": "456 Elm St, Dummyville", "value": "456 Elm St, Dummyville"},
{"label": "789 Oak St, Faketown", "value": "789 Oak St, Faketown"},
{"label": "101 Pine St, Dummy Falls", "value": "101 Pine St, Dummy Falls"},
{"label": "202 Maple St, Imaginary Town", "value": "202 Maple St, Imaginary Town"},
{"label": "303 Cedar St, Pretendville", "value": "303 Cedar St, Pretendville"}
]
this data I'm getting from Api Response. I don't know why this giving me error
Thanks for your help

@LyDawei
Copy link

LyDawei commented Jan 26, 2024

provide a key value on each of those objects. https://react.dev/learn/rendering-lists#rules-of-keys

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

2 participants