R
Refine

ask-any-question

Onsearch is not working in multiselect

Iinland-turquoise2/14/2023
const { selectProps: enumSelect } = useSelect({ resource: "enum_days", metaData: { fields: ["value", "label"], }, optionLabel: "label", optionValue: "value", onSearch: value => [ { field: "value", operator: "contains", value, }, ], }); <Select mode="multiple" size="large" placeholder={"Select Days"} {...enumSelect} />
Cconscious-sapphire2/14/2023
Hi, I am refine support bot :wave:. I am here to help you with your question. I searched for the answer to your question in the refine documentation and found an answer! 🏆
Answer: The onSearch property allows us to AutoComplete the options. SOURCES: ./docs/api-reference/core/hooks/useSelect/index.md

Note: If this is the answer you need, then we are very lucky. If not, please wait for someone from the refine core team or the community to try to help you.
Iinland-turquoise2/14/2023
i am using hasura dataprovider
Aadverse-sapphire2/14/2023
I couldn't understand what the problem. Can you prepare a codesandbox that I can repro?

Looking for more? Join the community!

R
Refine

ask-any-question

Join Server