Genie Discord forum

Author AvatarDearRude
5/9/2023, 6:57:11 AM

I'm trying to make a q-select component where I could have text filter. I can't workaround how to replicate filterFn function. Is there a MWE available?

Author AvatarPere
5/10/2023, 12:49:54 PM

What does this "filterFn" do? Are you trying to replicate this? https://codepen.io/rachitpant/pen/mdbpvda

(I'm still not sure what it does)

Author Avatarabhimanyuaryan
5/10/2023, 7:48:10 PM

but this is a very old example. You'll need to migrate to new API

Author AvatarDearRude
5/12/2023, 7:37:33 PM

Yes. All it does is to add the ability to search through the selection list by typing. I think the filterFn is to get the matched items and called each time the input box is changed.

Author AvatarBatman96
5/27/2023, 6:59:33 PM

quasar(:select, # your fields goes here #, var"v-on:filter" = "filterFn") define filterFn in Stipple.js_methods and you're good if you want to call filterFn everytime input box is changed you can use methods like js_computed or v-model