pjc2007 commented on issue #1112:
URL: 
https://github.com/apache/cordova-android/issues/1112#issuecomment-998525983


   > > That looks like what I want to do. Can I get the Cordova build to do 
this for me?
   > 
   > Yes. Create a network_security_config.xml file somewhere, and add it to 
your config.xml as a resource-file to be copied into the Android platform, and 
then use edit-config to point the AndroidManifest to it:
   > 
   > ```
   > <!-- in your config.xml file -->
   > <platform name="android">
   >   <resource-file src="path/to/network_security_config.xml" 
target="app/src/main/res/xml/network_security_config.xml" />
   > 
   >   <edit-config file="app/src/main/AndroidManifest.xml" mode="merge" 
target="/manifest/application">
   >     <application 
android:networkSecurityConfig="@xml/network_security_config" />
   >   </edit-config>
   > </platform>
   > ```
   
   Perfect exactly what I was after. Thankyou!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to