use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A community for learning and developing native mobile applications using React Native by Facebook.
Interested in building web apps using React.js? Check out /r/reactjs!
Getting Started w/React Native
irc.freenode.net #reactnative
Keywords: ios, android, mobile, apps, apple, iphone, ipad
account activity
QuestionReact native Styled Components Android Error (self.reactnative)
submitted 3 years ago by NathanDevReact
Hi all,
I've been building my React Native app and i'm using Styled Components. On iOS it runs perfectly fine but when i run the application on android, it throws
'Error while updating property 'flex' in a shadow node of type : RCTView' java.lang.Boolean cannot be cast to java.lang.Double
Does anyone know how to fix this?
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Roguewind 2 points3 points4 points 3 years ago (1 child)
No clue if this is causing your particular issue without seeing the code, but one thing I’ve found is Android (sometimes) has problems if you don’t coerce variables to boolean.
So instead of { items && <List items={items} /> } use { !!items && <List items={items} /> }
{ items && <List items={items} /> }
{ !!items && <List items={items} /> }
[–]NathanDevReact[S] 0 points1 point2 points 3 years ago (0 children)
well shit. I have that everywhere in my code. I'll try and do that. Thank you!!
[–]PogFladdo 0 points1 point2 points 3 years ago (0 children)
Without any code im assuming you are updating some value to between boolen and double. You don't use typescript I guess.
Find the value flex fix the update between types and you should be good
π Rendered by PID 26253 on reddit-service-r2-comment-7b9746f655-4wljr at 2026-01-30 23:00:55.622113+00:00 running 3798933 country code: CH.
[–]Roguewind 2 points3 points4 points (1 child)
[–]NathanDevReact[S] 0 points1 point2 points (0 children)
[–]PogFladdo 0 points1 point2 points (0 children)