1

I am trying out react native navigation(v2) for my app, and I can't get it to change the background color of my statusbar.

I am able to change the background color of my topBar, but that doesn't affect the statusbar background color. In iOS statusbar color automatically takes the same color as the tintcolor given to the top bar, how do I replicate the same here?

Amit
  • 3,952
  • 7
  • 46
  • 80

1 Answers1

1

You can use the Statusbar api directly from react-native to your Parent App level Component

To set the StatusBar to translucent you can pass it as a prop as mentioned here and change the backgroundColor according to your needs as

<StatusBar translucent backgroundColor={'#fff'}/>
Pritish Vaidya
  • 21,561
  • 3
  • 58
  • 76
  • that doesn't help since I need to control the statusbar from react-native-navigation, whcih needs the view controller based setting to be YES, while StatusBar(react) needs it to be NO – Amit May 03 '18 at 06:53