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

Fix filter vs filters warning #9980

Merged
merged 1 commit into from
Jul 8, 2024
Merged

Conversation

djhi
Copy link
Collaborator

@djhi djhi commented Jul 8, 2024

Problem

When passing an array of inputs to the filter prop, the list component behave weirdly and developers might loose time finding that they should have used filters instead.

Solution

Check that developers have pass either an element or an array of elements and throw an error

How to test

  • Open the simple example PostList file and change filters to filterin PostListDesktop
  • Run the example

@djhi djhi added the RFR Ready For Review label Jul 8, 2024
@adguernier adguernier self-requested a review July 8, 2024 14:32
@adguernier adguernier merged commit 0b3636d into master Jul 8, 2024
14 checks passed
@adguernier adguernier deleted the fix-filter-vs-filters-warning branch July 8, 2024 14:37
@adguernier adguernier added this to the 5.0.4 milestone Jul 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
RFR Ready For Review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants