You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi. I'm tryna get this filter array thingy to work properly:
let isFiction = ['non-fiction','fiction'];
When selecting non-fiction, the table shows all of my nonfiction book notes as desired, but selecting fiction shows both non-fiction and fiction books. How would I change the filter array to not include non-fiction when selecting fiction? I can easily do this with normal Dataview, but don’t know how on dataviewjs. Is this currently possible? Or is this somewhat related to one of the issues you mentioned on the README?
There is no way to exclude values. Might change the checkboxes to custom divs with states so you can chose wheter you want to turn it off, include or exclude from the filter.
The text was updated successfully, but these errors were encountered:
Write the frontmatter as fiction: Yes and fiction: No and use "Yes" and "No" as the values you search for (like i did for "concentration" in the Spells example)
Change your frontmatter key values to arrays, so if you have something like type: fiction you would change it into type: [fiction] or
type:
- fiction
After that change the if statement in isChecked function from
if (fltArr.length > 0) {
match = fltArr.some(r => q[categories[i].fmName].includes(r));
}
to
if (fltArr.length > 0) {
match = fltArr.some(r => {
if (q[categories[i].fmName].indexOf(r) != -1) { return true }
});
}
I haven't really had time to work on this unfortunatelly, but i hope this will help you for the time being.
Hi. I'm tryna get this filter array thingy to work properly:
let isFiction = ['non-fiction','fiction'];
When selecting
non-fiction
, the table shows all of my nonfiction book notes as desired, but selectingfiction
shows both non-fiction and fiction books. How would I change the filter array to not includenon-fiction
when selectingfiction
? I can easily do this with normal Dataview, but don’t know how on dataviewjs. Is this currently possible? Or is this somewhat related to one of the issues you mentioned on the README?The text was updated successfully, but these errors were encountered: