react-admin icon indicating copy to clipboard operation
react-admin copied to clipboard

[email protected] breaks list search filter with [email protected]

Open palmique opened this issue 8 months ago • 5 comments

What you were expecting: Search filter input of list view works as documented.

What happened instead: Search filter input crashes browser once it gets focused.

Steps to reproduce: Focus search filter input ("q").

Related code: Just use sample code from React-Admin's "Get started".

Other information: Issue was introduced after upgrading to [email protected] Seems to be major upgrade which requires react@^9.0.0 As workaround, use override in your project's package.json:

"overrides": { "react-admin": { "react-hook-form": "~7.54.0" } },

Environment

  • React-admin version: 4.16
  • Last version that did not exhibit the issue (if applicable):
  • React version: 8.2
  • Browser: Chrome, Edge
  • Stack trace (in case of a JS error):

palmique avatar Apr 11 '25 10:04 palmique

Thanks for the report. A sandbox reproducing the issue would have been welcome. But I managed to reproduce. Indeed there seems to be an infinite render loop. Note: The issue is not present in React Admin v5

slax57 avatar Apr 11 '25 14:04 slax57

bug reproduction for : React-admin version: 5.6.4 React version: 18.3.1 Browser: google chrome

Image when if fact there is a title named "Qui tempore rerum et voluptates" like showed in this screenshot

Image

saloua-ch avatar Apr 16 '25 12:04 saloua-ch

Can you link to a reproduction please ? Either a codesandbox, or a repository.

fzaninotto avatar Apr 16 '25 16:04 fzaninotto

@saloua-ch In the simple demo the title filter is an exact match filter, not a 'like' filter. As I said, I tested for the issue in RA v5 and it is not present. It only affects v4.

slax57 avatar Apr 17 '25 16:04 slax57

@slax57 thank you dor the clarification

saloua-ch avatar May 11 '25 19:05 saloua-ch