If I use a dark splashscreen and test it the app on a iPhone 6 or SE I get a white flicker when the SplashScreen is handed over from the native LaunchScreen.storyboard and to the SplashScreen plugin.
The duration of the flicker depends on the phone.
This new config param would allow me to reduce the flickering for splashscreen images with a small logo in the middle and remove the flickering for splash screens with a solid color.
Entry example for capacitor.config.json
ios {
backgroundColor: "#000000" or "rgba(0,0,0,1)" // convert it in the viewcontroller
}
rgba or hex color values are easier to configure than the UIColor.
Set the color in CAPBridgeViewController where the wkWebView is initialised.
// get config color an convert it to UIColor(
webView?.backgroundColor = //UIColor(red:0.15, green:0.17, blue:0.22, alpha:1.0)
webView?.scrollView.backgroundColor = //UIColor(red:0.15, green:0.17, blue:0.22, alpha:1.0)
For anyone using the workaround in XCode 10 do "Product / Clean Build Folder" (Cmd + Shift + K) before every build because XCode caches things and you will not see your changes.
Thx & BR, Michael
Other config params are described in #1097
+1 for this, highly needed
Thanks we should fix this for sure especially given the rising popularity of dark UI styles
Most helpful comment
+1 for this, highly needed