skip to Main Content

I have made a project with react native. now I want to generate an apk. but there isn’t any generated icon as below picture and also there isn’t exist Gradle script at the root of my project.

enter image description here

I think the Gradle script does not in the root project, is this the problem with Gradle?

2

Answers


  1. Open android folder in android studio, you will see Gradle, libraries and can build apk, also if you want to generate a release apk you can do it with this command in android folder directory ./gradlew assembleRelease or gradlew assembleRelease

    Login or Signup to reply.
  2. Run npx react-native run-android --variant=release from the android folder.
    You can find the apk in:

    'project_name'/android/app/build/outputs/apk/release
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search