Type error: Type '{ size: number; color: string; ref: MutableRefObject<SVGElement>; }' is not assignable to type 'IntrinsicAttributes & Props & { children?: ReactNode; }'.
Property 'ref' does not exist on type 'IntrinsicAttributes & Props & { children?: ReactNode; }'. Did you mean 'href'?
Not sure what type to use for forwardRef function component, but seems like FC doesn't include any ref property 🤔
I'm moving a project to TypeScript and I can't use ref :)
The code:
The compiler error:
Not sure what type to use for
forwardRef
function component, but seems likeFC
doesn't include anyref
property 🤔