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 |
resolver |
| instance |
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 |
options |
| The options for the dialog box. |
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 |
source |
| Observable class which emits the event. |
eventName |
| string The event name. |
handler |
| (eventData: EventData) => void The function which should be called when event occurs. |
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 |
options |
| Specifies the options for the alert box. |
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 |
options |
| Specifies the options for the confirm box. |
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 |
view |
| Starting view (child view). |
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
Parameter | Default | Description |
text |
| string |
textTransform |
|
Returns string
getViewById
Gets a child view by id.
Parameter | Default | Description |
view |
| The parent (container) view of the view to look for. |
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 |
options |
| The options for the dialog box. |
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 |
options |
| The options for the dialog box. |
Returns Promise<PromptResult>
querySelectorAll
Gets a child view by selector.
Parameter | Default | Description |
view |
| The parent (container) view of the view to look for. |
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 |
source |
| Observable class which emits the event. |
eventName |
| string The event name. |
handler |
| (eventData: EventData) => void The function which should be called when event occurs. |
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