Need to check if "style" prop is an array
Opened this issue · 5 comments
thomasttvo commented
this.props = { ...this.props, style: [customProps.style, this.props.style] };
when this.props.style
is an array, this will not work properly. In my case, it ignores customProps.style
mahesh1996 commented
Yes. Need to check for both customProps.style
and this.props.style
.
thomasttvo commented
@mahesh1996 while you're at it, can you take a look at #10 ? I suspect they're related. Thank you!
mahesh1996 commented
@thomasttvo Tested on react-native 0.51. It works fine as Text
can accept style object or recursive array of style objects.
thomasttvo commented
@mahesh1996 I got it on some elements too, but have deleted the code, will let you know if I happen to reproduce it.
mahesh1996 commented
Also, make sure If you are using native-base
in your project, then Text
is imported from react-native
.