Closed utkarshchowdhary closed 3 years ago
I'm not sure how this is related to the prop-types
package.
I don't know where the issue lies , i'm using prop-types package for documenting props for a component where i wanna pass styles specific to TEXT Component as a prop but specifying TextPropTypes.style for the style prop inside static propTypes object doesn't work it throws TypeError. It's working for ViewPropTypes.style though.
Right but that’s about react or your own code - TextPropTypes and ViewPropTypes don’t come from this package,
Oh Okay, if so can u demonstrate a working example of how would i pass a style object as a prop specific to TEXT Component and utilize prop-types package to validate that ?
This package exports specific validators. If you’re not using one, this repo isn’t the place to get help, I’m afraid.
ah, thanks anyway.
Referencing TextPropTypes.style for setting Text style prop for a component throws type error.