cordova-plugin-statusbar
cordova-plugin-statusbar copied to clipboard
Add example configuration on how to hide splash screen on startup on iOS
Extend tutorial for hiding at startup. One does not need to directly change Xcode project to hide splash screen. It can be made through config.xml
Platforms affected
What does this PR do?
What testing has been done on this change?
Checklist
- [ ] Reported an issue in the JIRA database
- [ ] Commit message follows the format: "CB-3232: (android) Fix bug with resolving file paths", where CB-xxxx is the JIRA ID & "android" is the platform affected.
- [ ] Added automated test coverage as appropriate for this change.
Could you please take a look at my comments and suggestions @milseg? Thanks.
Shouldn't it be edit-config
?
https://stackoverflow.com/a/38013943
Also worth mentioning you need to remove/add the platform for it to work
@FlorentMasson If my memory serves right, both can use XML but only config-file
can parse .plist
files.
Re-adding a plugin is always required if changes are made to the plugin variables and platform re-adding is always required when changing other values. If those necessities are not documented then we should improve it over at https://github.com/apache/cordova-docs.
UIViewControllerBasedStatusBarAppearance
set to true
is required for the plugin to work, so setting it to false
will prevent it from working.
Will certainly also hide it on startup as desired, but the user won't be able to show it again.
I don't think we should be recommending this on the plugin docs as we do now, nor adding this change.
We are using the same two properties in production without any issues - and are able to hide/show the status bar programmatically.
The code even checks for _uiviewControllerBasedStatusBarAppearance
(e.g., in https://github.com/apache/cordova-plugin-statusbar/blob/master/src/ios/CDVStatusBar.m#L395))
Maybe I'm mistaken, too - Apple's docs are always terrible.
yeah, if not using UIViewControllerBasedStatusBarAppearance
it uses setStatusBarHidden
, which was deprecated on iOS 9, if you say it still works then they might have not removed it yet, I didn't try before commenting