Replies: 1 comment
-
import { useAsync } from "react-select/async";
import Select from "react-select";
const asyncProps = useAsync({
isMulti: true,
loadOptions: promiseOptions,
getOptionLabel: (x) => x.value,
});
return (
<div >
<Select {...asyncProps} />
</div>
);``` |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
This documentation here mentions a
useAsync
hook, but it only shows it imported. It would be great to have an example of it's usage somewhere in documentation.Beta Was this translation helpful? Give feedback.
All reactions