F8app: undefined is not a function(evaluating 'StatusBarIOS.setStyle('default')')

Created on 2 Jul 2016  ·  6Comments  ·  Source: fbsamples/f8app

undefined is not a function(evaluating 'StatusBarIOS.setStyle('default')')

Most helpful comment

It is fixed and pushed by a user in #79 but unfortunately the code has not been merged yet.
Fixes you need:
js -> Login -> LoginScreen.js
Add "var StatusBar = require('StatusBar');" after line 31
At line 47, replace StatusBarIOS.setStyle('default') with StatusBar.setBarStyle('default'); since StatusBarIOS is deprecated https://facebook.github.io/react-native/docs/statusbarios.html.
This should fix it for you!

All 6 comments

Same

It is fixed and pushed by a user in #79 but unfortunately the code has not been merged yet.
Fixes you need:
js -> Login -> LoginScreen.js
Add "var StatusBar = require('StatusBar');" after line 31
At line 47, replace StatusBarIOS.setStyle('default') with StatusBar.setBarStyle('default'); since StatusBarIOS is deprecated https://facebook.github.io/react-native/docs/statusbarios.html.
This should fix it for you!

@naveensingh-daffodil Thanks a lot!

@naveensingh-daffodil Thanks !

react-native run-android

Same here!

undefined is not a function(evaluating 'StatusBarIOS.setStyle('default')')

PRs are welcome!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pythonsir picture pythonsir  ·  10Comments

hhashmi picture hhashmi  ·  9Comments

hasanobss picture hasanobss  ·  6Comments

brucebnu picture brucebnu  ·  4Comments

etamity picture etamity  ·  4Comments