react-native statusBar with expo on iOS

11,000

You can't change the color of the iOS status bar.

You can use the React Native StatusBar module to either hide it, or set the text color to light (white) or dark (black).

You can just drop the component in your app's root component:

 <StatusBar barStyle="light-content" /> 
Share:
11,000
Ayyoub
Author by

Ayyoub

Updated on June 28, 2022

Comments

  • Ayyoub
    Ayyoub almost 2 years

    I was trying to change the color of the statusBar on my react-native app.

    I am working with expo and on their documentation they are just specifying to add : "androidStatusBar": { "backgroundColor": "#2E1D59" }

    that works fine with android, but they did not mention how to do so with iOS statusBar.

    Anyone has an idea about this ?