react-native-svg-transformer
react-native-svg-transformer copied to clipboard
README doc casting type React.FC<SvgProps> on {...props}
Where?
https://github.com/kristerkari/react-native-svg-transformer#using-typescript
What to add?
If you want to spread unknown props
into the component you have cast type React.FC<SvgProps>
on it.
<Logo width={120} height={40} {...props as React.FC<SvgProps>}/>
Why?
It took me a while to get why I had an error. Yeah, I know that it looks obvious at first, but I will know it earlier it would save me time.
Thanks for your plugin anyway, keep it up with great work!