Change Package Name - React Native

How to change package name in React Native?


To change the package name in react application

1. Use react-native-rename npm package
Install react-native-rename package using 
> npm install react-native-rename

then, execute from root of the project
react-native-rename "MyApp" -b com.mycompany.myapp 

2. 
a. For iOS change package name from xcode.
b. For Android open build.gradle in android/app to find 

// ...
defaultConfig {
     applicationId com.myapp
     // ...
}
// ...

then, change com.myapp to your package name. After doing this, do 
> ./gradlew clean
> ./gradlew app:assembleRelease