You started building your app before you knew what it was, didn’t you? Well, that is certainly what I did.
My app started as “SlackBird”, then I realized that i may be violating some trademark there ( hint: probably not “bird” ), so I went and changed the name to “TLDR“. But after that I realized my addiction to Party Parrot so “TeamParrot” it is!
So what files should I actually change?
IOS
- When you go to project details in Xcode, you can edit name. When you edit it, Xcode “Rename files” tool opens.
- In
ios/PROJECT/info.plist
changeCFBundleURLName
- In ios/PROJECT.xcodeproj/xcshareddata/xcschemes/PROJECT.xcscheme
change
BuildableName` - Rename file
ios/PROJECT.xcodeproj/xcshareddata/xcschemes/PROJECT.xcscheme
itself toNEWPROJECT.xcsccheme
Android
I just grepped for files containing my old name “TLDR” in this instance. These variables needed to be changed:
package
inandroid/app/BUCK
applicationId
inandroid/app/build.gradle
package
inandroid/app/src/main/AndroidManifest.xml
- return value of
getMainComponentName
inandroid/app/src/main/java/com/slackbird/MainActivity.java
. That is the name of your main component in JavaScript portion. package
inandroid/app/src/main/java/com/PROJECT/MainApplication.java
- Application name in
android/app/src/main/res/values/strings.xml
React part
Now you renamed your min entry point to your application. So don’t forget to rename your main component name:
AppRegistry.registerComponent( 'TeamParrot', () => Login );
If you renamed everything, some directories will still have old name of your app. I decided I’m fine with that.
React Native Isomorphic app over the weekend
This article is part of my “React Native Isomorphic app over the weekend” series. It shares the problems I encountered during development of TeamParrot and Headstart Journal.
[display-posts tag=”React-Native-Weekend” wrapper=”ul”]
1 Comment