plugin-seed
plugin-seed copied to clipboard
How to update the application ID?
I tried modifyingapps\demo\nativescript.config.ts like the following which works for iOS. But it does not work for Android.
import { NativeScriptConfig } from '@nativescript/core';
export default {
- id: 'org.nativescript.plugindemo',
+ id: 'com.xulihang.nativescript',
appResourcesPath: '../../tools/assets/App_Resources',
android: {
v8Flags: '--expose_gc',
markingMode: 'none',
},
appPath: 'src',
cli: {
packageManager: 'npm'
}
} as NativeScriptConfig;
@xulihang You set the bundle ID in package.json
We read this value in our nativesceript.config.ts
Of course, these are just demo apps and this configuration is from an actual project so you will need to amend the paths to suit your demos.
import { NativeScriptConfig } from '@nativescript/core';
import { readFileSync } from 'fs';
const { name } = JSON.parse(readFileSync('./package.json', 'utf-8'));
export default {
name,
id: name,
appResourcesPath: 'App_Resources',
android: {
v8Flags: '--expose_gc',
markingMode: 'none'
},
useLegacyWorkflow: true,
} as NativeScriptConfig;