How is the app name set in iOS version of the build?
Looking at app/App_Resources/iOS/Info.plist - I see
<key>CFBundleDisplayName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
How are these 2 set and when are they set (during prepare?)?
NativeScript is a free and open-source framework for developing mobile applications. It is used to build truly native mobile apps using JavaScript. You can easily develop a native UI and higher-performance apps for your iOS and Android platforms using Angular skills.
By default, the name of the app is same as PRODUCT_NAME, which in return is the project name (the root-folder name of your app). EXECUTABLE_NAME is the name of the .ipa file that is generated. I would recommend to leave these two alone, the way they are :)
You can add the following to the Info.plist in order to set your own name:
<key>CFBundleDisplayName</key>
<string>My App</string>
UPDATE: If you need to fetch values from the Info.plist file, you can do it like this:
var utils = require("utils/utils");
var mainBundle = utils.ios.getter(NSBundle, NSBundle.mainBundle);
var appName = mainBundle.infoDictionary.objectForKey("CFBundleDisplayName"));
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With