This code causes StatusBar components to be overwritten in multiple scenarios and cause flicker if userInterfaceStyle is dark and statusbar should be light and vice versa.
Execution
By removing the StatusBar component from the Root.
Test Plan
Have an app with userInterfaceStyle set to dark. Place a StatusBar component in the _layout root set to dark. Without this PR the status bar is light, but with this PR status bar is dark.
Motivation
This code causes StatusBar components to be overwritten in multiple scenarios and cause flicker if userInterfaceStyle is dark and statusbar should be light and vice versa.
Execution
By removing the StatusBar component from the Root.
Test Plan
Have an app with userInterfaceStyle set to dark. Place a StatusBar component in the _layout root set to dark. Without this PR the status bar is light, but with this PR status bar is dark.