const { MenuList } = components;
const CustomMenuList = ({ ...props }: any) => {
console.log(props);
return (
<div>
<MenuList {...props} />
<hr className="m-0" />
<div
className="text-primary p-2 font-weight-bold c-pointer"
onClick={() => history.push(CUSTOM_POST.replace(':type', 'contact-roles'))}
>
+ Create New Role
</div>
</div>
);
};
I am utilizing TypeScript. I am implementing a Custom Component in ReactSelect.
What might be the expected data type of props? I have constraints against using 'any' due to tslint restrictions.
<Select
components={{
MenuList: CustomMenuList,
}}
options={[...contactRoleOptions]}
/>