API Index
Summary β
References
Namespaces
Enumerations
Classes
- AbsoluteLayout
- ActionBar
- ActionItem
- ActionItems
- ActivityIndicator
- AndroidApplication
- Animation
- ApplicationCommon
- Background
- Binding
- Builder
- Button
- ChangeType
- CoercibleProperty
- Color
- ContainerView
- ContentView
- ControlStateChangeListener
- CssAnimationParser
- CssAnimationProperty
- CssProperty
- CustomLayoutView
- DatePicker
- DockLayout
- EditableTextBase
- FadeTransition
- File
- FileSystemEntity
- FlexboxLayout
- Folder
- Font
- FormattedString
- Frame
- GesturesObserver
- GridLayout
- HtmlView
- Image
- ImageAsset
- ImageCache
- ImageSource
- InheritedCssProperty
- InheritedProperty
- iOSApplication
- ItemSpec
- KeyframeAnimation
- KeyframeAnimationInfo
- Label
- LayoutBase
- ListPicker
- ListView
- ModalTransition
- ModuleNameResolver
- NavigationButton
- Observable
- ObservableArray
- Page
- PageBase
- PageTransition
- ParserEventType
- Placeholder
- Progress
- Property
- ProxyViewContainer
- Repeater
- RootLayout
- Screen
- ScrollView
- SearchBar
- SegmentedBar
- SegmentedBarItem
- SharedTransition
- SharedTransitionHelper
- ShorthandProperty
- Slider
- SlideTransition
- Span
- StackLayout
- Style
- Switch
- TabView
- TabViewItem
- TextBase
- TextField
- TextView
- TimePicker
- TouchManager
- Transition
- View
- ViewBase
- ViewCommon
- ViewHelper
- VirtualArray
- WebView
- WrapLayout
- WrappedValue
- XmlParser
Interfaces
- ActionOptions
- AddArrayFromBuilder
- AddChildFromBuilder
- AlertOptions
- AndroidActivityBackPressedEventData
- AndroidActivityBundleEventData
- AndroidActivityCallbacks
- AndroidActivityEventData
- AndroidActivityNewIntentEventData
- AndroidActivityRequestPermissionsEventData
- AndroidActivityResultEventData
- AnimationDefinition
- ApplicationEventData
- BackstackEntry
- BindingOptions
- CancelableOptions
- ChangedData
- CommonLayoutParams
- ComponentModule
- ConfirmOptions
- CreateViewEventData
- CssChangedEventData
- DialogOptions
- DiscardedErrorEventData
- DownloadedData
- DownloadError
- DownloadRequest
- EventData
- FontScaleChangedEventData
- GestureEventData
- GestureEventDataWithState
- HttpContent
- HttpRequestOptions
- HttpResponse
- IDevice
- ImageAssetOptions
- ItemEventData
- ItemsLoading
- ItemsSource
- KeyedTemplate
- KeyframeDeclaration
- KeyframeInfo
- LaunchEventData
- LoadAppCSSEventData
- LoadEventData
- LoadOptions
- LoginOptions
- LoginResult
- NativeScriptConfig
- NativeScriptError
- NavigatedData
- NavigationContext
- NavigationEntry
- NavigationTransition
- OrientationChangedEventData
- PanGestureEventData
- ParserEvent
- PinchGestureEventData
- PlatformContext
- PromptOptions
- PromptResult
- PropertyChangeData
- RootLayoutOptions
- RotationGestureEventData
- ScrollEventData
- ShadeCoverOptions
- SharedTransitionConfig
- ShowModalOptions
- ShownModallyData
- Size
- SwipeGestureEventData
- SystemAppearanceChangedEventData
- TapGestureEventData
- Template
- TemplatedItemsView
- TimerInfo
- TouchGestureEventData
- TraceErrorHandler
- TraceEventListener
- TraceWriter
- UnhandledErrorEventData
- ViewEntry
Type Aliases
Variables
- _resetRootView
- addCss
- android
- androidDynamicElevationOffsetProperty
- androidElevationProperty
- AnimationCurve
- Application
- autocapitalizationTypeProperty
- autocorrectProperty
- backgroundColorProperty
- backgroundEvent
- backgroundImageProperty
- backgroundInternalProperty
- backgroundPositionProperty
- backgroundProperty
- backgroundRepeatProperty
- backgroundSizeProperty
- borderBottomColorProperty
- borderBottomLeftRadiusProperty
- borderBottomRightRadiusProperty
- borderBottomWidthProperty
- borderColorProperty
- borderLeftColorProperty
- borderLeftWidthProperty
- borderRadiusProperty
- borderRightColorProperty
- borderRightWidthProperty
- borderTopColorProperty
- borderTopLeftRadiusProperty
- borderTopRightRadiusProperty
- borderTopWidthProperty
- borderWidthProperty
- clipPathProperty
- colorProperty
- CSSHelper
- Device
- Dialogs
- discardedErrorEvent
- displayedEvent
- editableProperty
- Enums
- exitEvent
- fontFamilyProperty
- fontInternalProperty
- fontScaleChangedEvent
- fontScaleInternalProperty
- fontSizeProperty
- fontStyleProperty
- fontWeightProperty
- foregroundEvent
- getCssFileName
- getMainEntry
- getNativeApplication
- getResources
- getRootView
- hasLaunched
- hasListeners
- heightProperty
- hintProperty
- horizontalAlignmentProperty
- inBackground
- ios
- isAndroid
- isIOS
- isUserInteractionEnabledProperty
- keyboardTypeProperty
- launchEvent
- letterSpacingProperty
- lineHeightProperty
- loadAppCss
- lowMemoryEvent
- marginBottomProperty
- marginLeftProperty
- marginProperty
- marginRightProperty
- marginTopProperty
- maxLengthProperty
- minHeightProperty
- minWidthProperty
- notify
- off
- on
- opacityProperty
- orientation
- orientationChangedEvent
- paddingBottomProperty
- paddingLeftProperty
- paddingProperty
- paddingRightProperty
- paddingTopProperty
- placeholderColorProperty
- platformNames
- resetRootView
- resumeEvent
- returnKeyTypeProperty
- rotateProperty
- run
- scaleXProperty
- scaleYProperty
- setAutoSystemAppearanceChanged
- setCssFileName
- setMaxRefreshRate
- setResources
- suspended
- suspendEvent
- systemAppearance
- systemAppearanceChanged
- systemAppearanceChangedEvent
- textAlignmentProperty
- textDecorationProperty
- textShadowProperty
- textTransformProperty
- translateXProperty
- translateYProperty
- uncaughtErrorEvent
- unsetValue
- updateTextTriggerProperty
- verticalAlignmentProperty
- visibilityProperty
- whiteSpaceProperty
- widthProperty
- zeroLength
- zIndexProperty
Functions
- _setResolver
- action
- addTaggedAdditionalCSS
- addWeakEventListener
- alert
- animationTimingFunctionConverter
- booleanConverter
- confirm
- CSSType
- eachDescendant
- fromObject
- fromObjectRecursive
- getAncestor
- getCurrentPage
- getFileAccess
- getRootLayout
- getTransformedText
- getViewById
- login
- makeParser
- makeValidator
- parseCSSShadow
- parseKeyframeDeclarations
- profile
- profilingDisable
- profilingDumpProfiles
- profilingEnable
- profilingIsRunning
- profilingResetProfiles
- profilingStart
- profilingStartCPU
- profilingStop
- profilingStopCPU
- profilingTime
- profilingUptime
- prompt
- PseudoClassHandler
- querySelectorAll
- removeTaggedAdditionalCSS
- removeWeakEventListener
- resolveFileNameFromUrl
- setActivityCallbacks
- timeConverter
- transformConverter
References β
Type Aliases β
GridUnitType β
Headers β
defined in @nativescript/core/http/index.d.ts:127:12
HorizontalAlignment β
HorizontalAlignment: HorizontalAlignmentType
InstrumentationMode β
defined in @nativescript/core/profiling/index.d.ts:17:5
Profiling mode to use.
-
`counters`
Accumulates method call counts and times until dumpProfiles is called and then prints aggregated statistic in the console. This is the default.
- `timeline`
Outputs method names along start/end timestamps in the console on the go.
- `lifecycle`
Outputs basic non-verbose times for startup, navigation, etc.LengthDipUnit β
LengthDipUnit: LengthDipUnit
LengthPercentUnit β
LengthPercentUnit: LengthPercentUnit
LengthPxUnit β
LengthPxUnit: LengthPxUnit
LengthType β
LengthType: LengthType
ModuleListProvider β
PercentLengthType β
PercentLengthType: PercentLengthType
SharedTransitionTagProperties β
SharedTransitionTagProperties: SharedProperties & { callback?: (view: View, action: SharedTransitionEventAction) => Promise<void>; propertiesToMatch?: SharedTransitionTagPropertiesToMatch; }
Properties which can be set on individual Shared Elements
TouchAnimationOptions β
VerticalAlignment β
VerticalAlignment: VerticalAlignmentType
WebViewNavigationType β
dip β
percent β
px β
Variables β
AnimationCurve β
AnimationCurve: typeof AnimationCurve
Application β
Application: ApplicationCommon
CSSHelper β
CSSHelper: {
AttributeSelector: typeof AttributeSelector
ClassSelector: typeof ClassSelector
InvalidSelector: typeof InvalidSelector
PseudoClassSelector: typeof PseudoClassSelector
RuleSet: typeof RuleSet
Selector: typeof Selector
SelectorCore: typeof SelectorCore
SelectorsMap: typeof SelectorsMap
SelectorsMatch: typeof SelectorsMatch
SimpleSelector: typeof SimpleSelector
SimpleSelectorSequence: typeof SimpleSelectorSequence
TypeSelector: typeof TypeSelector
UniversalSelector: typeof UniversalSelector
createSelector: typeof createSelector
}
Dialogs β
Enums β
Enums: { Accuracy: typeof Accuracy; AndroidActionBarIconVisibility: typeof AndroidActionBarIconVisibility; AndroidActionItemPosition: typeof AndroidActionItemPosition; AnimationCurve: typeof AnimationCurve; AutocapitalizationType: typeof AutocapitalizationType; BackgroundRepeat: typeof BackgroundRepeat; DeviceOrientation: typeof DeviceOrientation; DeviceType: typeof DeviceType; Dock: typeof Dock; FontAttributes: typeof FontAttributes; FontStyle: typeof FontStyle; FontWeight: typeof FontWeight; HorizontalAlignment: typeof HorizontalAlignment; IOSActionItemPosition: typeof IOSActionItemPosition; ImageFormat: typeof ImageFormat; KeyboardType: typeof KeyboardType; NavigationBarVisibility: typeof NavigationBarVisibility; Orientation: typeof Orientation; ReturnKeyType: typeof ReturnKeyType; StatusBarStyle: typeof StatusBarStyle; Stretch: typeof ImageStretch; SystemAppearance: typeof SystemAppearance; TextAlignment: typeof TextAlignment; TextDecoration: typeof TextDecoration; TextTransform: typeof TextTransform; UpdateTextTrigger: typeof UpdateTextTrigger; VerticalAlignment: typeof VerticalAlignment; Visibility: typeof Visibility; }
_resetRootView β
addCss β
android β
androidDynamicElevationOffsetProperty β
androidDynamicElevationOffsetProperty: CssProperty<Style, number>
androidElevationProperty β
androidElevationProperty: CssProperty<Style, number>
autocapitalizationTypeProperty β
autocapitalizationTypeProperty: Property<EditableTextBase, AutocapitalizationInputType>
autocorrectProperty β
autocorrectProperty: Property<EditableTextBase, boolean>
backgroundColorProperty β
backgroundColorProperty: CssAnimationProperty<Style, Color>
backgroundEvent β
backgroundImageProperty β
backgroundImageProperty: CssProperty<Style, string>
backgroundInternalProperty β
backgroundInternalProperty: CssProperty<Style, Background>
backgroundPositionProperty β
backgroundPositionProperty: CssProperty<Style, string>
backgroundProperty β
backgroundProperty: ShorthandProperty<Style, string>
backgroundRepeatProperty β
backgroundRepeatProperty: CssProperty<Style, BackgroundRepeatType>
backgroundSizeProperty β
backgroundSizeProperty: CssProperty<Style, string>
borderBottomColorProperty β
borderBottomColorProperty: CssProperty<Style, Color>
borderBottomLeftRadiusProperty β
borderBottomLeftRadiusProperty: CssProperty<Style, LengthType>
borderBottomRightRadiusProperty β
borderBottomRightRadiusProperty: CssProperty<Style, LengthType>
borderBottomWidthProperty β
borderBottomWidthProperty: CssProperty<Style, LengthType>
borderColorProperty β
borderColorProperty: ShorthandProperty<Style, string | Color>
borderLeftColorProperty β
borderLeftColorProperty: CssProperty<Style, Color>
borderLeftWidthProperty β
borderLeftWidthProperty: CssProperty<Style, LengthType>
borderRadiusProperty β
borderRadiusProperty: ShorthandProperty<Style, string | LengthType>
borderRightColorProperty β
borderRightColorProperty: CssProperty<Style, Color>
borderRightWidthProperty β
borderRightWidthProperty: CssProperty<Style, LengthType>
borderTopColorProperty β
borderTopColorProperty: CssProperty<Style, Color>
borderTopLeftRadiusProperty β
borderTopLeftRadiusProperty: CssProperty<Style, LengthType>
borderTopRightRadiusProperty β
borderTopRightRadiusProperty: CssProperty<Style, LengthType>
borderTopWidthProperty β
borderTopWidthProperty: CssProperty<Style, LengthType>
borderWidthProperty β
borderWidthProperty: ShorthandProperty<Style, string | LengthType>
clipPathProperty β
clipPathProperty: CssProperty<Style, string>
colorProperty β
colorProperty: InheritedCssProperty<Style, Color>
discardedErrorEvent β
displayedEvent β
editableProperty β
editableProperty: Property<EditableTextBase, boolean>
exitEvent β
fontFamilyProperty β
fontFamilyProperty: InheritedCssProperty<Style, string>
fontInternalProperty β
fontInternalProperty: InheritedCssProperty<Style, Font>
fontScaleChangedEvent β
fontScaleInternalProperty β
fontScaleInternalProperty: InheritedCssProperty<Style, number>
fontSizeProperty β
fontSizeProperty: InheritedCssProperty<Style, number>
fontStyleProperty β
fontStyleProperty: InheritedCssProperty<Style, FontStyleType>
fontWeightProperty β
fontWeightProperty: InheritedCssProperty<Style, FontWeightType>
foregroundEvent β
getCssFileName β
getMainEntry β
getNativeApplication β
getResources β
getRootView β
hasLaunched β
hasListeners β
heightProperty β
heightProperty: CssAnimationProperty<Style, PercentLengthType>
hintProperty β
hintProperty: Property<EditableTextBase, string>
horizontalAlignmentProperty β
horizontalAlignmentProperty: CssProperty<Style, HorizontalAlignmentType>
inBackground β
ios β
isAndroid β
defined in @nativescript/core/platform/index.d.ts:10:13
Gets a value indicating if the app is running on the Android platform.
isIOS β
defined in @nativescript/core/platform/index.d.ts:15:13
Gets a value indicating if the app is running on the iOS platform.
isUserInteractionEnabledProperty β
keyboardTypeProperty β
keyboardTypeProperty: Property<EditableTextBase, KeyboardInputType>
launchEvent β
letterSpacingProperty β
letterSpacingProperty: CssProperty<Style, number>
lineHeightProperty β
lineHeightProperty: CssProperty<Style, number>
loadAppCss β
lowMemoryEvent β
marginBottomProperty β
marginBottomProperty: CssProperty<Style, PercentLengthType>
marginLeftProperty β
marginLeftProperty: CssProperty<Style, PercentLengthType>
marginProperty β
marginProperty: ShorthandProperty<Style, string | PercentLengthType>
marginRightProperty β
marginRightProperty: CssProperty<Style, PercentLengthType>
marginTopProperty β
marginTopProperty: CssProperty<Style, PercentLengthType>
maxLengthProperty β
maxLengthProperty: Property<EditableTextBase, number>
minHeightProperty β
minHeightProperty: CssProperty<Style, dip | LengthDipUnit | LengthPxUnit>
minWidthProperty β
minWidthProperty: CssProperty<Style, dip | LengthDipUnit | LengthPxUnit>
notify β
off β
on β
opacityProperty β
opacityProperty: CssAnimationProperty<Style, number>
orientation β
orientationChangedEvent β
paddingBottomProperty β
paddingBottomProperty: CssProperty<Style, LengthType>
paddingLeftProperty β
paddingLeftProperty: CssProperty<Style, LengthType>
paddingProperty β
paddingProperty: ShorthandProperty<Style, string | LengthType>
paddingRightProperty β
paddingRightProperty: CssProperty<Style, LengthType>
paddingTopProperty β
paddingTopProperty: CssProperty<Style, LengthType>
placeholderColorProperty β
placeholderColorProperty: CssProperty<Style, Color>
platformNames β
defined in @nativescript/core/platform/index.d.ts:20:13
resetRootView β
resumeEvent β
returnKeyTypeProperty β
returnKeyTypeProperty: Property<EditableTextBase, ReturnKeyButtonType>
rotateProperty β
rotateProperty: CssAnimationProperty<Style, number>
run β
scaleXProperty β
scaleXProperty: CssAnimationProperty<Style, number>
scaleYProperty β
scaleYProperty: CssAnimationProperty<Style, number>
setAutoSystemAppearanceChanged β
setCssFileName β
setMaxRefreshRate β
setResources β
suspendEvent β
suspended β
systemAppearance β
systemAppearanceChanged β
systemAppearanceChangedEvent β
textAlignmentProperty β
textAlignmentProperty: InheritedCssProperty<Style, TextAlignmentType>
textDecorationProperty β
textDecorationProperty: CssProperty<Style, TextDecorationType>
textShadowProperty β
textShadowProperty: CssProperty<Style, CSSShadow>
textTransformProperty β
textTransformProperty: CssProperty<Style, TextTransformType>
translateXProperty β
translateXProperty: CssAnimationProperty<Style, dip>
translateYProperty β
translateYProperty: CssAnimationProperty<Style, dip>
uncaughtErrorEvent β
unsetValue β
Value specifying that Property should be set to its initial value.
updateTextTriggerProperty β
updateTextTriggerProperty: Property<EditableTextBase, UpdateTextTriggerType>
verticalAlignmentProperty β
verticalAlignmentProperty: CssProperty<Style, VerticalAlignmentType>
visibilityProperty β
visibilityProperty: CssProperty<Style, VisibilityType>
whiteSpaceProperty β
whiteSpaceProperty: CssProperty<Style, WhiteSpaceType>
widthProperty β
widthProperty: CssAnimationProperty<Style, PercentLengthType>
zIndexProperty β
zIndexProperty: CssProperty<Style, number>
zeroLength β
zeroLength: LengthType
Functions β
CSSType β
Specifies the type name for the instances of this View class,
that is used when matching CSS type selectors.
Usage:
```
@CSSType("Button")
class Button extends View {
}
```
Internally the decorator set `Button.prototype.cssType = "Button"`
. Parameter Default Description
type
string
The type name, e. g. "Button", "Label", etc.
Returns ClassDecorator
PseudoClassHandler β
Parameter Default Description
pseudoClasses
string[]
Returns MethodDecorator
_setResolver β
_setResolver(resolver: ModuleNameResolver): any
Used to set a global singular instance of ModuleNameResolver
Parameter Default Description
Returns any
action β
defined in @nativescript/core/ui/dialogs/index.d.ts:129
The action() method displays a action box that prompts the visitor to choose some action.
Parameter Default Description
message
string
The text to display in the dialog box.
cancelButtonText
string
The text to display in the cancel button.
actions
string[]
List of available actions.
Returns Promise<string>
action(options: ActionOptions): Promise<string>
defined in @nativescript/core/ui/dialogs/index.d.ts:135
The action() method displays a action box that prompts the visitor to choose some action.
Parameter Default Description
Returns Promise<string>
addTaggedAdditionalCSS β
Parameter Default Description
cssText
string
tag
string | Number
Returns boolean
addWeakEventListener β
addWeakEventListener(source: Observable, eventName: string, handler: (eventData: EventData) => void, target: any): void
Attaches a WeakEventListener.
Parameter Default Description
eventName
string
The event name.
target
any
Subscriber (target) of the event listener. It will be used as a thisArg in the handler function.
Returns void
alert β
defined in @nativescript/core/ui/dialogs/index.d.ts:66
The alert() method displays an alert box with a specified message.
Parameter Default Description
message
string | number | boolean
Specifies the text to display in the alert box.
Returns Promise<void>
alert(options: AlertOptions): Promise<void>
defined in @nativescript/core/ui/dialogs/index.d.ts:72
The alert() method displays an alert box with a specified message.
Parameter Default Description
Returns Promise<void>
animationTimingFunctionConverter β
Parameter Default Description
value
string
Returns any
booleanConverter β
Parameter Default Description
v
string | boolean
Returns boolean
confirm β
defined in @nativescript/core/ui/dialogs/index.d.ts:78
The confirm() method displays a dialog box with a specified message.
Parameter Default Description
message
string
Specifies the text to display in the confirm box.
Returns Promise<boolean>
confirm(options: ConfirmOptions): Promise<boolean>
defined in @nativescript/core/ui/dialogs/index.d.ts:84
The confirm() method displays a dialog box with a specified message.
Parameter Default Description
Returns Promise<boolean>
eachDescendant β
Iterates through all child views (via visual tree) and executes a function.
Returns void
fromObject β
fromObject(source: any): Observable
Creates an Observable instance and sets its properties according to the supplied JavaScript object.
param obj - A JavaScript object used to initialize nativescript Observable instance.
Parameter Default Description
source
any
Returns Observable
fromObjectRecursive β
fromObjectRecursive(source: any): Observable
Creates an Observable instance and sets its properties according to the supplied JavaScript object.
This function will create new Observable for each nested object (expect arrays and functions) from supplied JavaScript object.
param obj - A JavaScript object used to initialize nativescript Observable instance.
Parameter Default Description
source
any
Returns Observable
getAncestor β
Gets an ancestor from a given type.
Parameter Default Description
criterion
string | () => any
The type of ancestor view we are looking for. Could be a string containing a class name or an actual type.
Returns an instance of a view (if found), otherwise undefined.
Returns ViewBase
getFileAccess β
defined in @nativescript/core/file-system/index.d.ts:22
Returns FileSystemAccess, a shared singleton utility class to provide methods to access and work with the file system. This is used under the hood of all the file system apis in @nativescript/core and provided as a lower level convenience if needed.
Returns FileSystemAccess
getRootLayout β
getRootLayout(): RootLayout
Returns RootLayout
getTransformedText β
getTransformedText(text: string, textTransform: TextTransformType): string
Returns string
getViewById β
Gets a child view by id.
Parameter Default Description
id
string
The id of the view to look for.
Returns an instance of a view (if found), otherwise undefined.
Returns ViewBase
login β
login(message: string, userNameHint?: string, passwordHint?: string, userName?: string, password?: string): Promise<LoginResult>
defined in @nativescript/core/ui/dialogs/index.d.ts:107
The login() method displays a login dialog box that prompts the visitor for user name and password.
Parameter Default Description
message
string
The text to display in the dialog box.
userNameHint
string
The default text to display as a hint in the username input. Optional.
passwordHint
string
The default text to display as a hint in the password input. Optional.
userName
string
The default text to display in the user name input box. Optional.
password
string
The default text to display in the password input box. Optional.
Returns Promise<LoginResult>
login(message: string, userNameHint?: string, passwordHint?: string): Promise<LoginResult>
defined in @nativescript/core/ui/dialogs/index.d.ts:115
The login() method displays a login dialog box that prompts the visitor for user name and password.
Parameter Default Description
message
string
The text to display in the dialog box.
userNameHint
string
The default text to display as a hint in the username input. Optional.
passwordHint
string
The default text to display as a hint in the password input. Optional.
Returns Promise<LoginResult>
login(options: LoginOptions): Promise<LoginResult>
defined in @nativescript/core/ui/dialogs/index.d.ts:121
The login() method displays a login dialog box that prompts the visitor for user name and password.
Parameter Default Description
Returns Promise<LoginResult>
makeParser β
Parameter Default Description
isValid
(value: any) => boolean
allowNumbers
boolean
Returns (value: any) => T
makeValidator β
Parameter Default Description
values
T[]
Returns (value: any) => value is T
parseCSSShadow β
Parse a string into a CSSShadow
Supports any valid css box/text shadow combination.
inspired by https://github.com/jxnblk/css-box-shadow/blob/master/index.js (MIT License)
Parameter Default Description
value
string
Returns CSSShadow
parseKeyframeDeclarations β
parseKeyframeDeclarations(unparsedKeyframeDeclarations: KeyframeDeclaration[]): KeyframeDeclaration[]
Parameter Default Description
unparsedKeyframeDeclarations
Returns KeyframeDeclaration[]
profile β
defined in @nativescript/core/profiling/index.d.ts:98
Method decorator factory. It will intercept the method call and start and pause a timer before and after the method call.
Works only if profiling is enabled.
Parameter Default Description
name
string
Name of the timer which will be used for method calls. If not provided - the name of the method will be used.
Returns MethodDecorator
defined in @nativescript/core/profiling/index.d.ts:105
Function factory. It will intercept the function call and start and pause a timer before and after the function call. Works only if profiling is enabled.
Works only if profiling is enabled.
Parameter Default Description
fn
F
The function to wrap. Uses the function name to track the times.
Returns F
defined in @nativescript/core/profiling/index.d.ts:112
Function factory. It will intercept the function call and start and pause a timer before and after the function call. Works only if profiling is enabled.
Parameter Default Description
name
string
The name used to track calls and times.
fn
F
The function to wrap.
Returns F
profile<T>(target:Object, propertyKey:string|symbol, descriptor:TypedPropertyDescriptor<T>):TypedPropertyDescriptor<T> |void
defined in @nativescript/core/profiling/index.d.ts:117
Method decorator. It will intercept the method calls and start and pause a timer before and after the method call. Works only if profiling is enabled.
Parameter Default Description
target
Object
propertyKey
string | symbol
descriptor
TypedPropertyDescriptor<T>
Returns TypedPropertyDescriptor<T> | void
defined in @nativescript/core/profiling/index.d.ts:118
Returns any
profilingDisable β
profilingDumpProfiles β
defined in @nativescript/core/profiling/index.d.ts:123
Prints the timer for all methods instrumented with profile decorator.
Returns void
profilingEnable β
profilingEnable(type?: InstrumentationMode): void
defined in @nativescript/core/profiling/index.d.ts:53
Enables profiling.
Upon loading of the module it will cache the package.json of the app and check if there is a "profiling" key set,
its value can be one of the options available for InstrumentationMode, and if set,
enable() will be called in pre app start with the value in the package.json.
An example for an
`app/package.json`
enabling the manual instrumentation profiling is:
```
{
"main": "main.js",
"profiling": "timeline"
}
```
Parameter Default Description
type
Profiling mode to use.
- "counters" - Accumulates method call counts and times until dumpProfiles is called and then prints aggregated statistic in the console. This is the default.
- "timeline" - Outputs method names along start/end timestamps in the console on the go.
- "lifecycle" - Outputs basic non-verbose times for startup, navigation, etc.
Returns void
profilingIsRunning β
defined in @nativescript/core/profiling/index.d.ts:91
Returns true if a timer is currently running.
Parameter Default Description
name
string
Name of the timer.
Returns boolean
profilingResetProfiles β
defined in @nativescript/core/profiling/index.d.ts:128
Resets the timers for all methods instrumented with profile decorator.
Returns void
profilingStart β
defined in @nativescript/core/profiling/index.d.ts:70
Starts a timer with a specific name.
Works only if profiling is enabled.
Parameter Default Description
name
string
Name of the timer.
Returns void
profilingStartCPU β
defined in @nativescript/core/profiling/index.d.ts:134
Starts android cpu profiling.
Parameter Default Description
name
string
Name of the cpu profiling session.
Returns void
profilingStop β
profilingStop(name: string): TimerInfo
defined in @nativescript/core/profiling/index.d.ts:78
Pauses a timer with a specific name. This will increase call count and accumulate time.
Works only if profiling is enabled.
Parameter Default Description
name
string
Name of the timer.
Returns TimerInfo
profilingStopCPU β
defined in @nativescript/core/profiling/index.d.ts:140
Stops android cpu profiling.
Parameter Default Description
name
string
Name of the cpu profiling session.
Returns void
profilingTime β
defined in @nativescript/core/profiling/index.d.ts:63
Gets accurate system timestamp in ms.
Returns number
profilingUptime β
defined in @nativescript/core/profiling/index.d.ts:145
Gets the uptime of the current process in milliseconds.
Returns number
prompt β
prompt(message: string, defaultText?: string): Promise<PromptResult>
defined in @nativescript/core/ui/dialogs/index.d.ts:91
The prompt() method displays a dialog box that prompts the visitor for input.
Parameter Default Description
message
string
The text to display in the dialog box.
defaultText
string
The default text to display in the input box. Optional.
Returns Promise<PromptResult>
prompt(options: PromptOptions): Promise<PromptResult>
defined in @nativescript/core/ui/dialogs/index.d.ts:97
The prompt() method displays a dialog box that prompts the visitor for input.
Parameter Default Description
Returns Promise<PromptResult>
querySelectorAll β
Gets a child view by selector.
Parameter Default Description
selector
string
The selector of the view to look for.
Returns an instance of a view (if found), otherwise undefined.
Returns ViewBase[]
removeTaggedAdditionalCSS β
Parameter Default Description
tag
String | Number
Returns boolean
removeWeakEventListener β
removeWeakEventListener(source: Observable, eventName: string, handler: (eventData: EventData) => void, target: any): void
Removes a WeakEventListener.
Parameter Default Description
eventName
string
The event name.
target
any
Subscriber (target) of the event listener. It will be used as a thisArg in the handler function.
Returns void
resolveFileNameFromUrl β
setActivityCallbacks β
defined in @nativescript/core/ui/frame/index.d.ts:510
Parameter Default Description
activity
any
Returns void
timeConverter β
Parameter Default Description
value
string
Returns number
transformConverter β
Parameter Default Description
text
string
Returns TransformFunctionsInfo
- Next
- AccessibilityEvents
On this page
- Summary
- References
- Type Aliases
- Variables
- AnimationCurve
- Application
- CSSHelper
- Device
- Dialogs
- Enums
- _resetRootView
- addCss
- android
- androidDynamicElevationOffsetProperty
- androidElevationProperty
- autocapitalizationTypeProperty
- autocorrectProperty
- backgroundColorProperty
- backgroundEvent
- backgroundImageProperty
- backgroundInternalProperty
- backgroundPositionProperty
- backgroundProperty
- backgroundRepeatProperty
- backgroundSizeProperty
- borderBottomColorProperty
- borderBottomLeftRadiusProperty
- borderBottomRightRadiusProperty
- borderBottomWidthProperty
- borderColorProperty
- borderLeftColorProperty
- borderLeftWidthProperty
- borderRadiusProperty
- borderRightColorProperty
- borderRightWidthProperty
- borderTopColorProperty
- borderTopLeftRadiusProperty
- borderTopRightRadiusProperty
- borderTopWidthProperty
- borderWidthProperty
- clipPathProperty
- colorProperty
- discardedErrorEvent
- displayedEvent
- editableProperty
- exitEvent
- fontFamilyProperty
- fontInternalProperty
- fontScaleChangedEvent
- fontScaleInternalProperty
- fontSizeProperty
- fontStyleProperty
- fontWeightProperty
- foregroundEvent
- getCssFileName
- getMainEntry
- getNativeApplication
- getResources
- getRootView
- hasLaunched
- hasListeners
- heightProperty
- hintProperty
- horizontalAlignmentProperty
- inBackground
- ios
- isAndroid
- isIOS
- isUserInteractionEnabledProperty
- keyboardTypeProperty
- launchEvent
- letterSpacingProperty
- lineHeightProperty
- loadAppCss
- lowMemoryEvent
- marginBottomProperty
- marginLeftProperty
- marginProperty
- marginRightProperty
- marginTopProperty
- maxLengthProperty
- minHeightProperty
- minWidthProperty
- notify
- off
- on
- opacityProperty
- orientation
- orientationChangedEvent
- paddingBottomProperty
- paddingLeftProperty
- paddingProperty
- paddingRightProperty
- paddingTopProperty
- placeholderColorProperty
- platformNames
- resetRootView
- resumeEvent
- returnKeyTypeProperty
- rotateProperty
- run
- scaleXProperty
- scaleYProperty
- setAutoSystemAppearanceChanged
- setCssFileName
- setMaxRefreshRate
- setResources
- suspendEvent
- suspended
- systemAppearance
- systemAppearanceChanged
- systemAppearanceChangedEvent
- textAlignmentProperty
- textDecorationProperty
- textShadowProperty
- textTransformProperty
- translateXProperty
- translateYProperty
- uncaughtErrorEvent
- unsetValue
- updateTextTriggerProperty
- verticalAlignmentProperty
- visibilityProperty
- whiteSpaceProperty
- widthProperty
- zIndexProperty
- zeroLength
- Functions
- CSSType
- PseudoClassHandler
- _setResolver
- action
- addTaggedAdditionalCSS
- addWeakEventListener
- alert
- animationTimingFunctionConverter
- booleanConverter
- confirm
- eachDescendant
- fromObject
- fromObjectRecursive
- getAncestor
- getCurrentPage
- getFileAccess
- getRootLayout
- getTransformedText
- getViewById
- login
- makeParser
- makeValidator
- parseCSSShadow
- parseKeyframeDeclarations
- profile
- profilingDisable
- profilingDumpProfiles
- profilingEnable
- profilingIsRunning
- profilingResetProfiles
- profilingStart
- profilingStartCPU
- profilingStop
- profilingStopCPU
- profilingTime
- profilingUptime
- prompt
- querySelectorAll
- removeTaggedAdditionalCSS
- removeWeakEventListener
- resolveFileNameFromUrl
- setActivityCallbacks
- timeConverter
- transformConverter