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

Ensure indices are not used as React keys #15

Open
sergei-maertens opened this issue Mar 15, 2023 · 0 comments
Open

Ensure indices are not used as React keys #15

sergei-maertens opened this issue Mar 15, 2023 · 0 comments

Comments

@sergei-maertens
Copy link
Member

For example: https://github.com/open-formulieren/formio-renderer/pull/4/files#diff-9185d63b2c63822bf756d0c5012592387413b1089b5ea674d96d922e159e4e15R74

This causes problems when lists are being mutated - e.g. repeating groups (edit grid) with 3 items where item at index 0 or 1 is deleted -> react won't re-render the old item 0 and 1.

This should be properly asserted with user interaction tests in storybook.

@sergei-maertens sergei-maertens changed the title Ensure indexes are not used as React keys Ensure indices are not used as React keys Mar 15, 2023
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

1 participant