diff --git a/package.json b/package.json index 445162952..a83039951 100644 --- a/package.json +++ b/package.json @@ -7,11 +7,11 @@ "start": "nps", "changelog": "conventional-changelog -p angular -i CHANGELOG.md -s" }, - "private": true, - "repository": { - "type": "git", - "url": "https://github.com/NativeScript/NativeScript.git" - }, + "private": true, + "repository": { + "type": "git", + "url": "https://github.com/NativeScript/NativeScript.git" + }, "dependencies": { "nativescript-theme-core": "^1.0.4" }, diff --git a/packages/core/config/config.interface.ts b/packages/core/config/config.interface.ts index ff1528f7b..57ccf5cc2 100644 --- a/packages/core/config/config.interface.ts +++ b/packages/core/config/config.interface.ts @@ -1,4 +1,6 @@ -interface IConfigPlaform { +import type {InstrumentationMode} from '../profiling' + +interface IConfigPlatform { /** * App's bundle id */ @@ -10,9 +12,10 @@ interface IConfigPlaform { discardUncaughtJsExceptions?: boolean; } -interface IConfigIOS extends IConfigPlaform {} +// eslint-disable-next-line @typescript-eslint/no-empty-interface +interface IConfigIOS extends IConfigPlatform {} -interface IConfigAndroid extends IConfigPlaform { +interface IConfigAndroid extends IConfigPlatform { /** * These are the v8 runtime flags you can pass in, you must have "--expose_gc" as this is used in the runtime */ @@ -46,11 +49,6 @@ interface IConfigAndroid extends IConfigPlaform { */ gcThrottleTime?: number; - /** - * Enabled "timeline" profiling by setting this key to "timeline", default: "" - */ - profiling?: string; - /** * "none" & "full" is supported, "full" is depreciated * Default: none @@ -91,8 +89,8 @@ interface IConfigAndroid extends IConfigPlaform { enableLineBreakpoints?: boolean; /** - * Enabled the multithreaded JavaScript engine, this will probably break plugins... - * Disabled/Default: false + * Enable the multithreaded JavaScript engine, this will probably break plugins... + * Default: false - disabled. */ enableMultithreadedJavascript?: boolean; } @@ -104,9 +102,13 @@ export interface NativeScriptConfig { */ id?: string; /** - * App's main entry file + * App's main entry file (currently ignored - set it in package.json main field) */ main?: string; + /** + * Path to the app source directory + * This is often the `src` or `app` directory however can be changed. + */ appPath?: string; /** * App_Resources path @@ -131,4 +133,15 @@ export interface NativeScriptConfig { * Various Android specific configurations including Android runtime flags. */ android?: IConfigAndroid; + /** + * Enable profiling for the application. Default: no profiling + * In most cases when profiling, you will want to use "timeline" + */ + profiling?: InstrumentationMode; + /** + * Set the default CSS parser that NativeScript will use. + * Default: css-tree + */ + cssParser?: 'rework' | 'nativescript' | 'css-tree'; } +