Onsearch is not working in multiselect
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}
/>
3 Replies
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
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.
rival-black•2y ago
i am using hasura dataprovider
foreign-sapphire•2y ago
I couldn't understand what the problem. Can you prepare a
codesandbox
that I can repro?