Some optimizations for Cordova (Plugin and config.xml)
DAnn2012 opened this issue · comments
- The
cordova-plugin-splashscreen
is installed for both iOS and Android, but starting from version 6.0.0 of Cordova for iOS it is integrated.
framework7-cli/create/utils/get-options.js
Lines 284 to 290 in aff2010
https://cordova.apache.org/news/2020/06/13/plugins-release.html
Splash Screen
In the Cordova-iOS 6.x platform, the splash screen feature has been integrated into its core and no longer needs this plugin. This release prevents the plugin from being added to the iOS 6.x platform.GH-261 chore: add cordova-ios requirement <6.0.0
- Some improvements that could be made to these lines of the
config.xml
file which are added to all platforms:
framework7-cli/create/templates/generate-config-xml.js
Lines 84 to 91 in aff2010
<preference name="BackupWebStorage" value="local" />
is only for iOS
<preference name="ShowSplashScreenSpinner" value="false" />
is only for Android (in the version of splashscreen integrated in Cordova for iOS it seems to be no longer there)
<preference name="Suppresses3DTouchGesture" value="true" />
is only for iOS
<preference name="Allow3DTouchLinkPreview" value="false" />
it was for cordova-plugin-wkwebview-engine, which has now been removed
<preference name="CordovaWebViewEngine" value="CDVWKWebViewEngine" />
is only for iOS
<preference name="AllowInlineMediaPlayback" value="true" />
is only for iOS
https://cordova.apache.org/docs/en/latest/config_ref/index.html#preference
Thanks.
There is nothing to do with it, if some preferences/plugin is added for both platforms but supported only by specific platform, it will be picked up correctly, and just ignored by other platform