Answers for "how to change package name in react native"

1

react native rename package name

npx react-native-rename "Travel App" -b com.packagename
Posted by: Guest on August-15-2021
2

how to change package name in react native

I have changed project subfolder name from:
"android/app/src/main/java/MY/APP/OLD_ID/"
to: "android/app/src/main/java/MY/APP/NEW_ID/"

Then manually switched the old and new package ids:

In: android/app/src/main/java/MY/APP/NEW_ID/MainActivity.java:

package MY.APP.NEW_ID;
In android/app/src/main/java/MY/APP/NEW_ID/MainApplication.java:

package MY.APP.NEW_ID;
In android/app/src/main/AndroidManifest.xml:

package="MY.APP.NEW_ID"
And in android/app/build.gradle:

applicationId "MY.APP.NEW_ID"
(Optional) In android/app/BUCK:

android_build_config(
  package="MY.APP.NEW_ID"
)
android_resource(
  package="MY.APP.NEW_ID"
)
Gradle' cleaning in the end (in /android folder):

./gradlew clean
Posted by: Guest on March-18-2020

Code answers related to "how to change package name in react native"

Code answers related to "Javascript"

Browse Popular Code Answers by Language