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

form.mutators.removeBatch Removes wrong data #97

Open
xilovesyu opened this issue Jun 19, 2023 · 1 comment
Open

form.mutators.removeBatch Removes wrong data #97

xilovesyu opened this issue Jun 19, 2023 · 1 comment

Comments

@xilovesyu
Copy link

Are you submitting a bug report or a feature request?

Bug report

What is the current behavior?

removed data by id from 5 -10

What is the expected behavior?

Should remove id from 4 to 16 and keep the data with id 1 to 3

Sandbox Link

Sandbox Link Here

What's your environment?

"final-form": "4.20.9",
"final-form-arrays": "3.1.0",
"loader-utils": "3.2.1",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-final-form": "6.5.9",
"react-final-form-arrays": "3.1.4"

Other information

@xilovesyu
Copy link
Author

Seems https://github.com/final-form/final-form-arrays/blob/master/src/removeBatch.js#L38 we should use sort there.

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