I am building a button component:
interface ButtonProps {
startIcon?: ... <-- what type?
}
const Button = ({startIcon: StartIcon}) => {
return <button>{StartIcon && <StartIcon/>}</button>
}
// usage
<Button startIcon={SomeIcon}/>
I am using react-icons library, what type should I declare in interface? Does it make a difference on type declaration if I pass svg element as startIcon prop?