For android version 9 and above, http requests wont be successful for your react native apps and this may lead to app crashes simply because RN's networking native module blocks insecure connections by default.
The best solution is to change your api calls to https, however if its a must for you to use http then head over to your main AndroidManifest.xml file and add this line
xmlns:tools="http://schemas.android.com/tools" to the <manifest tag so it looks like so,
<manifest xmlns:tools="http://schemas.android.com/tools">
PS. do not delete any other code inside the <manifest
we aren't done.. head down to the <application tag and add android:usesCleartextTraffic="true" tools:targetApi="28" so it looks like so <application android:usesCleartextTraffic="true" tools:targetApi="28" >
There you have it. Enjoy
For further actions, you may consider blocking this person and/or reporting abuse
Top comments (1)
Awezome! Thanks