Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

react native rename package name

npx react-native-rename "Travel App" -b com.packagename
Comment

how to change package name in ios react native

I use the react-native-rename npm package.

Install using

npm install react-native-rename -g

Then from the root of your React Native project execute the following

react-native-rename "MyApp" -b com.mycompany.myapp
Comment

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
Comment

PREVIOUS NEXT
Code Example
Javascript :: angular http get status code 
Javascript :: print array without brackets javascript 
Javascript :: array map 
Javascript :: js string replace array 
Javascript :: lodash find 
Javascript :: vue js hooks 
Javascript :: disable URL encoder javascript 
Javascript :: jest tranform image 
Javascript :: bookmarklets 
Javascript :: jquery add class except this 
Javascript :: convert html to pdf using javascript 
Javascript :: js setinterval vs settimeout 
Javascript :: react maps 
Javascript :: plotly express bar graph 
Javascript :: lodash find all in array 
Javascript :: try catch javascript 
Javascript :: regex negate 
Javascript :: refresh a single component 
Javascript :: javascript get cell by index 
Javascript :: for loop in javascript 
Javascript :: js or 
Javascript :: js copy text 
Javascript :: canvas tag html 
Javascript :: autocomplete react jsx attributes vscode 
Javascript :: angular selector 
Javascript :: redux reducer 
Javascript :: legend on click use default chartjs 
Javascript :: how to get location javascript 
Javascript :: how to sum variables to an array in javascript 
Javascript :: toggle password hide show 
ADD CONTENT
Topic
Content
Source link
Name
8+2 =