Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need to check if "style" prop is an array #8

Open
thomasttvo opened this issue Apr 30, 2018 · 5 comments
Open

Need to check if "style" prop is an array #8

thomasttvo opened this issue Apr 30, 2018 · 5 comments

Comments

@thomasttvo
Copy link

thomasttvo commented Apr 30, 2018

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
Copy link

mahesh1996 commented May 1, 2018

Yes. Need to check for both customProps.style and this.props.style.

@thomasttvo
Copy link
Author

@mahesh1996 while you're at it, can you take a look at #10 ? I suspect they're related. Thank you!

@thomasttvo thomasttvo reopened this May 1, 2018
@mahesh1996
Copy link

@thomasttvo Tested on react-native 0.51. It works fine as Text can accept style object or recursive array of style objects.

@thomasttvo
Copy link
Author

@mahesh1996 I got it on some elements too, but have deleted the code, will let you know if I happen to reproduce it.

@mahesh1996
Copy link

Also, make sure If you are using native-base in your project, then Text is imported from react-native.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants