marmelab / react-admin

A frontend Framework for single-page applications on top of REST/GraphQL APIs, using TypeScript, React and Material Design
http://marmelab.com/react-admin
MIT License
24.89k stars 5.23k forks source link

update on useWarnWhenUnsavedChanges with react-router useBlock #9325

Open mikel-k-khui opened 1 year ago

mikel-k-khui commented 1 year ago

Is your feature request related to a problem? Please describe. The current implementation of useWarnWhenUnsavedChanges seem to fail silently due to react-router change. https://marmelab.com/react-admin/Form.html#warnwhenunsavedchanges

Describe the solution you'd like Is there plan to update this with the new react-router changes in 6.4.

djhi commented 1 year ago

Yes, we'll work on this when we can. As this is documented, we don't consider it a bug though:

Besides, the hooks we need are still unstable. See https://marmelab.com/react-admin/TabbedForm.html#warnwhenunsavedchanges