Skip to content

Missing piece in upgrade guide to 0.59 #23949

@mehulmpt

Description

@mehulmpt

Local development builds fail with targetSdkVersion 28 because starting from Android 9, clearText support is disabled (https://developer.android.com/training/articles/security-config#CleartextTrafficPermitted). It is not mentioned anywhere in the docs, maybe we could include it somewhere?

To make sure the app is able to communicate with metro bundler, you need to add android:usesCleartextTraffic="true" to your AndroidManifest.xml file so it should finally look something like:

 <application
      android:name=".MainApplication"
      //...
      android:icon="@mipmap/ic_launcher"
	  android:usesCleartextTraffic="true" <-- add this
    // ....
>

If you don't add this, your app would build and launch but would fail with the following screen:

error

Metadata

Metadata

Assignees

No one assigned

    Labels

    Resolution: FixedA PR that fixes this issue has been merged.Resolution: LockedThis issue was locked by the bot.Type: DocsIssues concerning the docs are tracked elsewhere: https://github.com/facebook/react-native-website

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions