Cordova Slack Digest

Wed, 03 Nov 2021 08:21:11 GMT

User count: 4669

Join the conversation at slack.cordova.io

Channel #cordova-android (13 messages)


Wed, 03 Nov 2021 03:04:02 GMT

@mathewp.94 says

Are there any known issues targeting Android SDK 30 while using Cordova-Android 9.1.0?

Wed, 03 Nov 2021 03:04:29 GMT

@mathewp.94 says

Just been tripped up by Google updating the minimum version

Wed, 03 Nov 2021 03:07:49 GMT

@dpogue says

yeah, there was some security tightening around file:/// URLs (which Cordova uses by default). In cordova-android 10 we've added the ability to use a custom hostname, as recommended by Google.

Wed, 03 Nov 2021 03:08:04 GMT

@dpogue says

It sortof matches what we do on iOS now

Wed, 03 Nov 2021 03:10:26 GMT

@mathewp.94 says

Right

Wed, 03 Nov 2021 03:10:38 GMT

@mathewp.94 says

I'm assuming if I was using those I would know about it? 😂

Wed, 03 Nov 2021 03:10:49 GMT

@mathewp.94 says

I suppose one of my plugins could be using it behind my back

Wed, 03 Nov 2021 03:12:46 GMT

@mathewp.94 says

Or when you say “Cordova uses by default”, cordova itself is using it to function and will break unless I update to cordova-android 10+?

Wed, 03 Nov 2021 03:13:57 GMT

@dpogue says

In a default cordova-android 9.x app, the files in the www folder are served from file:/// URLs

Wed, 03 Nov 2021 03:14:44 GMT

@dpogue says

so unless you‘ve pointed it to a web server or are doing something special with a local server plugin, you’re probably using file URLs and might be affected by the permission changes that Google enforces with SDK 30

Wed, 03 Nov 2021 03:15:06 GMT

@mathewp.94 says

ok great

Wed, 03 Nov 2021 03:15:09 GMT

@mathewp.94 says

Time to do some testing

Wed, 03 Nov 2021 03:25:52 GMT

@mathewp.94 says

If I set this preference in my config.xml <preference name="android-targetSdkVersion" value="30" /> and run cordova prepare android the build.gradle file should have defaultTargetSdkVersion=30 correct?