I use cordova cli to build my application. I want to target both Android and ios (maybe more).
As I want this to be true for all platforms, I was hoping I could simply define this as a preference in the config.xml file as follows:
<preference name="orientation" value="landscape" />
because this is apparently how it works in the phonegap assembly https://build.phonegap.com/docs/config-xml
I assume that the functions supported in the config.xml file using the phonegap assembly are different from the cordova-cli functions?
I know that I can force it to be inserted android:screenOrientation="landscape"into my AndroidManifest.xml in an Android application , but that’s not good, because it will be rewritten the next time I execute cordova build.
Any suggestions?
source
share