I tried the JavaScript solution above and got no joy
In Visual Studio 2015 I change the config.xml to
<preference name="orientation" value="all" />
taken from Cordova 5 build command is deleting iOS device orientation settings
I didn’t need the javascript just the config setting