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

filter folders by null #274

Closed
robsonsobral opened this issue Dec 12, 2024 · 4 comments
Closed

filter folders by null #274

robsonsobral opened this issue Dec 12, 2024 · 4 comments
Assignees
Labels
enhancement New feature or request

Comments

@robsonsobral
Copy link

Hi!

Thank you for making a better version of Decap.

May I suggest you to make filter parameter of folders to accept null, so we can filter for entries without a specific field?

Thank you!

@kyoshino
Copy link
Member

Sure! Should be easy.

@kyoshino kyoshino self-assigned this Dec 12, 2024
@kyoshino kyoshino added the enhancement New feature or request label Dec 12, 2024
@kyoshino
Copy link
Member

I’ll also solve decaporg/decap-cms#7347 reported today.

@kyoshino
Copy link
Member

kyoshino commented Dec 12, 2024

By the way in Sveltia CMS, unlike Decap/Netlify CMS, all fields are saved even if optional, so the filter may not work as expected. It will be useful once the new output.omit_empty_optional_fields option is added in #241. Anyway I’m going to implement this.

The filter accepts an array, so you’ll be able to write filter: { field: field, value: [null, ''] } to match both an empty or undefined field.

@kyoshino
Copy link
Member

Solved in v0.49.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants