| title | ViewBase |
|---|---|
| titleTemplate | title - API / NativeScript |
| contributors | false |
Defined in: ui/core/view-base/index.ts
ViewBase
new ViewBase(): ViewBase;Defined in: ui/core/view-base/index.ts
ViewBase
_automaticallyAdjustsScrollViewInsets: boolean;Defined in: ui/core/view-base/index.ts
_context: any;Defined in: ui/core/view-base/index.ts
_cssState: CssState;Defined in: ui/core/view-base/index.ts
protected _defaultPaddingBottom: number;Defined in: ui/core/view-base/index.ts
protected _defaultPaddingLeft: number;Defined in: ui/core/view-base/index.ts
protected _defaultPaddingRight: number;Defined in: ui/core/view-base/index.ts
protected _defaultPaddingTop: number;Defined in: ui/core/view-base/index.ts
_domId: number;Defined in: ui/core/view-base/index.ts
_ignoreFlexMinWidthHeightReset: boolean;Defined in: ui/core/view-base/index.ts
_isAddedToNativeVisualTree: boolean;Defined in: ui/core/view-base/index.ts
protected _isPaddingRelative: boolean;Defined in: ui/core/view-base/index.ts
_isStyleScopeHost: boolean;Defined in: ui/core/view-base/index.ts
_oldBottom: number;Defined in: ui/core/view-base/index.ts
_oldLeft: number;Defined in: ui/core/view-base/index.ts
_oldRight: number;Defined in: ui/core/view-base/index.ts
_oldTop: number;Defined in: ui/core/view-base/index.ts
_styleScope: StyleScope;Defined in: ui/core/view-base/index.ts
_suspendNativeUpdatesCount: number;Defined in: ui/core/view-base/index.ts
Determines the depth of suspended updates. When the value is 0 the current property updates are not batched nor scoped and must be immediately applied. If the value is 1 or greater, the current updates are batched and does not have to provide immediate update. Do not set this field, the _batchUpdate method is responsible to keep the count up to date, as well as adding/rmoving the view to/from the visual tree.
alignSelf: AlignSelf;Defined in: ui/core/view-base/index.ts
(Android-only) Overrides the alignItems value for the child.
bindingContext: any;Defined in: ui/core/view-base/index.ts
className: string;Defined in: ui/core/view-base/index.ts
Gets or sets the CSS class name for this view.
col: number;Defined in: ui/core/view-base/index.ts
The column for the element. The columns are 0-indexed, so the first column is indicated by 0.
colSpan: number;Defined in: ui/core/view-base/index.ts
The number of columns for the element to span across.
column: number;Defined in: ui/core/view-base/index.ts
The column for the element. The columns are 0-indexed, so the first column is indicated by 0.
columnSpan: number;Defined in: ui/core/view-base/index.ts
readonly cssClasses: Set<string>;Defined in: ui/core/view-base/index.ts
readonly cssPseudoClasses: Set<string>;Defined in: ui/core/view-base/index.ts
defaultVisualState: string;Defined in: ui/core/view-base/index.ts
Default visual state, defaults to 'normal'
dock: "left" | "right" | "top" | "bottom";Defined in: ui/core/view-base/index.ts
Dock position of the view within its parent.
domNode: DOMNode;Defined in: ui/core/view-base/index.ts
effectiveBorderBottomWidth: number;Defined in: ui/core/view-base/index.ts
effectiveBorderLeftWidth: number;Defined in: ui/core/view-base/index.ts
effectiveBorderRightWidth: number;Defined in: ui/core/view-base/index.ts
effectiveBorderTopWidth: number;Defined in: ui/core/view-base/index.ts
effectiveColumnGap: number;Defined in: ui/core/view-base/index.ts
effectiveHeight: number;Defined in: ui/core/view-base/index.ts
effectiveLeft: number;Defined in: ui/core/view-base/index.ts
effectiveMarginBottom: number;Defined in: ui/core/view-base/index.ts
effectiveMarginLeft: number;Defined in: ui/core/view-base/index.ts
effectiveMarginRight: number;Defined in: ui/core/view-base/index.ts
effectiveMarginTop: number;Defined in: ui/core/view-base/index.ts
effectiveMaxHeight: number;Defined in: ui/core/view-base/index.ts
effectiveMaxWidth: number;Defined in: ui/core/view-base/index.ts
effectiveMinHeight: number;Defined in: ui/core/view-base/index.ts
effectiveMinWidth: number;Defined in: ui/core/view-base/index.ts
effectiveRowGap: number;Defined in: ui/core/view-base/index.ts
effectiveTop: number;Defined in: ui/core/view-base/index.ts
effectiveWidth: number;Defined in: ui/core/view-base/index.ts
flexGrow: number;Defined in: ui/core/view-base/index.ts
Indicates that the child should grow in size, if necessary. Sets how much the child will grow in proportion to the rest of the child elements in the flex container.
flexShrink: number;Defined in: ui/core/view-base/index.ts
Indicates that the child should shrink when the row runs out of space. Sets how much the flex item will shrink in proportion to the rest of the child elements in the flex container. When not specified, its value is set to 1.
flexWrapBefore: boolean;Defined in: ui/core/view-base/index.ts
When true, forces the item to wrap onto a new line.
hidden
hidden: boolean;Defined in: ui/core/view-base/index.ts
Gets or sets the visual state of the view.
id: string;Defined in: ui/core/view-base/index.ts
Gets or sets the id for this view.
isCollapsed: any;Defined in: ui/core/view-base/index.ts
Returns true if visibility is set to 'collapse'. Default(false) set in prototype Readonly property
left: LengthType;Defined in: ui/core/view-base/index.ts
Gets or sets the distance, in pixels, between the left edge of the child and the left edge of its parent.
nativeViewProtected: any;Defined in: ui/core/view-base/index.ts
read-only. If you want to set out-of-band the nativeView use the setNativeView method.
order: number;Defined in: ui/core/view-base/index.ts
Sets the order in which child elements inside a Flex appear in relation to one another.
parent: ViewBase;Defined in: ui/core/view-base/index.ts
Gets the parent view. This property is read-only.
recycleNativeView: "auto" | "always" | "never";Defined in: ui/core/view-base/index.ts
reusable: boolean;Defined in: ui/core/view-base/index.ts
Gets or sets if the view is reusable. Reusable views are not automatically destroyed when removed from the View tree.
row: number;Defined in: ui/core/view-base/index.ts
The row for the element. The rows are 0-indexed, so the first row is indicated by 0.
rowSpan: number;Defined in: ui/core/view-base/index.ts
The number of rows for the element to span across.
sharedTransitionIgnore: boolean;Defined in: ui/core/view-base/index.ts
Opt out of shared transition under different binding conditions
sharedTransitionTag: string;Defined in: ui/core/view-base/index.ts
Gets or sets the shared transition tag for animated view transitions
top: LengthType;Defined in: ui/core/view-base/index.ts
Gets or sets the distance, in pixels, between the top edge of the child and the top edge of its parent.
viewController: any;Defined in: ui/core/view-base/index.ts
returns the native UIViewController.
static createdEvent: string;Defined in: ui/core/view-base/index.ts
String value used when hooking to creation event
created
static disposeNativeViewEvent: string;Defined in: ui/core/view-base/index.ts
String value used when hooking to disposeNativeView event
disposeNativeView
static loadedEvent: string;Defined in: ui/core/view-base/index.ts
String value used when hooking to loaded event.
loaded
static propertyChangeEvent: string;Defined in: data/observable/index.ts
String value used when hooking to propertyChange event.
propertyChange
Observable.propertyChangeEvent
static unloadedEvent: string;Defined in: ui/core/view-base/index.ts
String value used when hooking to unloaded event.
unloaded
get android(): any;Defined in: ui/core/view-base/index.ts
any
get class(): string;Defined in: ui/core/view-base/index.ts
string
set class(v: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
v |
string |
void
get cssType(): string;Defined in: ui/core/view-base/index.ts
Gets the CSS fully qualified type name used for selector matching.
string
set cssType(value: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
value |
string |
void
get effectivePaddingBottom(): number;Defined in: ui/core/view-base/index.ts
number
set effectivePaddingBottom(v: number): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
v |
number |
void
get effectivePaddingLeft(): number;Defined in: ui/core/view-base/index.ts
number
set effectivePaddingLeft(v: number): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
v |
number |
void
get effectivePaddingRight(): number;Defined in: ui/core/view-base/index.ts
number
set effectivePaddingRight(v: number): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
v |
number |
void
get effectivePaddingTop(): number;Defined in: ui/core/view-base/index.ts
number
set effectivePaddingTop(v: number): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
v |
number |
void
get ios(): any;Defined in: ui/core/view-base/index.ts
any
get isLoaded(): boolean;Defined in: ui/core/view-base/index.ts
boolean
get nativeView(): any;Defined in: ui/core/view-base/index.ts
any
set nativeView(value: any): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
value |
any |
void
get page(): Page;Defined in: ui/core/view-base/index.ts
Gets owner page. This is a read-only property.
get parentNode(): ViewBase;Defined in: ui/core/view-base/index.ts
Gets the template parent or the native parent. Sets the template parent.
ViewBase
set parentNode(node: ViewBase): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
node |
ViewBase |
void
get style(): Style;Defined in: ui/core/view-base/index.ts
Gets the style object associated to this view.
set style(inlineStyle: Style): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
inlineStyle |
Style |
void
get typeName(): string;Defined in: ui/core/view-base/index.ts
Gets the name of the constructor function for this instance. E.g. for a Button class this will return "Button".
string
get visualState(): string;Defined in: ui/core/view-base/index.ts
string
_addView(view: ViewBase, atIndex?: number): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
view |
ViewBase |
atIndex? |
number |
void
_addViewCore(view: ViewBase, atIndex?: number): void;Defined in: ui/core/view-base/index.ts
Method is intended to be overridden by inheritors and used as "protected"
| Parameter | Type |
|---|---|
view |
ViewBase |
atIndex? |
number |
void
_addViewToNativeVisualTree(view: ViewBase, atIndex?: number): boolean;Defined in: ui/core/view-base/index.ts
Performs the core logic of adding a child view to the native visual tree. Returns true if the view's native representation has been successfully added, false otherwise. Method is intended to be overridden by inheritors and used as "protected".
| Parameter | Type |
|---|---|
view |
ViewBase |
atIndex? |
number |
boolean
_addVisualState(state: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
state |
string |
void
_applyXmlAttribute(attribute: string, value: string): boolean;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
attribute |
string |
value |
string |
boolean
This used to be the way to set attribute values in early {N} versions. Now attributes are expected to be set as plain properties on the view instances.
_batchUpdate<T>(callback: () => T): T;Defined in: ui/core/view-base/index.ts
Allow multiple updates to be performed on the instance at once.
| Type Parameter |
|---|
T |
| Parameter | Type |
|---|---|
callback |
() => T |
T
_childIndexToNativeChildIndex(index?: number): number;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
index? |
number |
number
_createPropertyChangeData(
propertyName: string,
value: any,
oldValue?: any): PropertyChangeData;Defined in: data/observable/index.ts
This method is intended to be overriden by inheritors to provide additional implementation.
| Parameter | Type |
|---|---|
propertyName |
string |
value |
any |
oldValue? |
any |
Observable._createPropertyChangeData
_dialogClosed(): void;Defined in: ui/core/view-base/index.ts
Method is intended to be overridden by inheritors and used as "protected"
void
_emit(eventName: string): void;Defined in: data/observable/index.ts
| Parameter | Type |
|---|---|
eventName |
string |
void
_goToVisualState(state: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
state |
string |
void
Use View._addVisualState() and View._removeVisualState() instead.
_inheritStyles(view: ViewBase): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
view |
ViewBase |
void
_inheritStyleScope(styleScope: StyleScope): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
styleScope |
StyleScope |
void
_layoutParent(): void;Defined in: ui/core/view-base/index.ts
void
_onRootViewReset(): void;Defined in: ui/core/view-base/index.ts
Method is intended to be overridden by inheritors and used as "protected"
void
_parentChanged(oldParent: ViewBase): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
oldParent |
ViewBase |
void
_removeView(view: ViewBase): void;Defined in: ui/core/view-base/index.ts
Core logic for removing a child view from this instance. Used by the framework to handle lifecycle events more centralized. Do not use outside the UI Stack implementation.
| Parameter | Type |
|---|---|
view |
ViewBase |
void
_removeViewCore(view: ViewBase): void;Defined in: ui/core/view-base/index.ts
Method is intended to be overridden by inheritors and used as "protected"
| Parameter | Type |
|---|---|
view |
ViewBase |
void
_removeViewFromNativeVisualTree(view: ViewBase): void;Defined in: ui/core/view-base/index.ts
Method is intended to be overridden by inheritors and used as "protected"
| Parameter | Type |
|---|---|
view |
ViewBase |
void
_removeVisualState(state: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
state |
string |
void
_resumeNativeUpdates(type: SuspendType): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
type |
SuspendType |
void
_setDefaultPaddings(insets: any): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
insets |
any |
void
_setupAsRootView(context: any): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
context |
any |
void
_setupUI(
context: any,
atIndex?: number,
parentIsLoaded?: boolean): void;Defined in: ui/core/view-base/index.ts
Setups the UI for ViewBase and all its children recursively. This method should not be overridden by derived views.
| Parameter | Type |
|---|---|
context |
any |
atIndex? |
number |
parentIsLoaded? |
boolean |
void
_shouldDelayLayout(): boolean;Defined in: ui/core/view-base/index.ts
When returning true the callLoaded method will be run in setTimeout Method is intended to be overridden by inheritors and used as "protected"
boolean
_suspendNativeUpdates(type: SuspendType): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
type |
SuspendType |
void
_tearDownUI(force?: boolean): void;Defined in: ui/core/view-base/index.ts
Tears down the UI for ViewBase and all its children recursively. This method should not be overridden by derived views.
| Parameter | Type |
|---|---|
force? |
boolean |
void
addEventListener(
eventName: string,
callback: (data: EventData) => void,
thisArg?: any,
once?: boolean): void;Defined in: data/observable/index.ts
Adds a listener for the specified event name.
| Parameter | Type | Description |
|---|---|---|
eventName |
string |
Name of the event to attach to. |
callback |
(data: EventData) => void |
A function to be called when some of the specified event(s) is raised. |
thisArg? |
any |
An optional parameter which when set will be used as "this" in callback method call. |
once? |
boolean |
An optional parameter which when set will cause the event listener to fire once. |
void
protected addPseudoClass(name: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
name |
string |
void
A widget can call this method to add a matching css pseudo class.
bind(options: BindingOptions, source?: Object): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
options |
BindingOptions |
source? |
Object |
void
callLoaded(): void;Defined in: ui/core/view-base/index.ts
void
callUnloaded(): void;Defined in: ui/core/view-base/index.ts
void
closeModal(...args: any[]): void;Defined in: ui/core/view-base/index.ts
Closes the current modal view that this page is showing.
| Parameter | Type |
|---|---|
...args |
any[] |
void
createNativeView(): Object;Defined in: ui/core/view-base/index.ts
Creates a native view. Returns either android.view.View or UIView.
Object
protected deletePseudoClass(name: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
name |
string |
void
A widget can call this method to discard matching css pseudo class.
destroyNode(forceDestroyChildren?: boolean): void;Defined in: ui/core/view-base/index.ts
Tears down the UI of a reusable node by making it no longer reusable.
| Parameter | Type | Description |
|---|---|---|
forceDestroyChildren? |
boolean |
Force destroy the children (even if they are reusable) |
void
_tearDownUI
disposeNativeView(): void;Defined in: ui/core/view-base/index.ts
Clean up references to the native view.
void
eachChild(callback: (child: ViewBase) => boolean): void;Defined in: ui/core/view-base/index.ts
Iterates over children of type ViewBase.
| Parameter | Type | Description |
|---|---|---|
callback |
(child: ViewBase) => boolean |
Called for each child of type ViewBase. Iteration stops if this method returns falsy value. |
void
ensureDomNode(): void;Defined in: ui/core/view-base/index.ts
void
Ensures a dom-node for this view.
get(name: string): any;Defined in: data/observable/index.ts
Gets the value of the specified property.
| Parameter | Type |
|---|---|
name |
string |
any
getEffectivePaddingShorthand(): string;Defined in: ui/core/view-base/index.ts
string
getViewByDomId<T>(domId: number): T;Defined in: ui/core/view-base/index.ts
Returns the child view with the specified domId.
| Type Parameter |
|---|
T extends ViewBase |
| Parameter | Type |
|---|---|
domId |
number |
T
getViewById<T>(id: string): T;Defined in: ui/core/view-base/index.ts
Returns the child view with the specified id.
| Type Parameter |
|---|
T extends ViewBase |
| Parameter | Type |
|---|---|
id |
string |
T
hasListeners(eventName: string): boolean;Defined in: data/observable/index.ts
Checks whether a listener is registered for the specified event name.
| Parameter | Type | Description |
|---|---|---|
eventName |
string |
The name of the event to check for. |
boolean
initNativeView(): void;Defined in: ui/core/view-base/index.ts
Initializes properties/listeners of the native view.
void
loadView(view: ViewBase): void;Defined in: ui/core/view-base/index.ts
Load view.
| Parameter | Type | Description |
|---|---|---|
view |
ViewBase |
to load. |
void
notify<T>(data: T): void;Defined in: data/observable/index.ts
Notify this Observable instance with some data. This causes all event handlers on the Observable instance to be called, as well as any 'global' event handlers set on the instance's class.
| Type Parameter |
|---|
T extends Optional<EventData, "object"> |
| Parameter | Type | Description |
|---|---|---|
data |
T |
an object that satisfies the EventData interface, though with an optional 'object' property. If left undefined, the 'object' property will implicitly be set as this Observable instance. |
void
notifyPropertyChange(
name: string,
value: any,
oldValue?: any): void;Defined in: data/observable/index.ts
Notifies all the registered listeners for the property change event.
| Parameter | Type |
|---|---|
name |
string |
value |
any |
oldValue? |
any |
void
Observable.notifyPropertyChange
off(
eventName: string,
callback?: (data: EventData) => void,
thisArg?: any): void;Defined in: data/observable/index.ts
Removes the listener(s) for the specified event name.
| Parameter | Type | Description |
|---|---|---|
eventName |
string |
The name of the event. |
callback? |
(data: EventData) => void |
An optional specific event listener to remove (if omitted, all event listeners by this name will be removed). |
thisArg? |
any |
An optional parameter which, when set, will be used to refine search of the correct event listener to be removed. |
void
on(
eventName: string,
callback: (data: EventData) => void,
thisArg?: any): void;Defined in: data/observable/index.ts
Adds a listener for the specified event name.
| Parameter | Type | Description |
|---|---|---|
eventName |
string |
The name of the event. |
callback |
(data: EventData) => void |
The event listener to add. Will be called when an event of the given name is raised. |
thisArg? |
any |
An optional parameter which, when set, will be bound as the this context when the callback is called. Falsy values will be not be bound. |
void
once(
eventName: string,
callback: (data: EventData) => void,
thisArg?: any): void;Defined in: data/observable/index.ts
Adds a listener for the specified event name, which, once fired, will remove itself.
| Parameter | Type | Description |
|---|---|---|
eventName |
string |
The name of the event. |
callback |
(data: EventData) => void |
The event listener to add. Will be called when an event of the given name is raised. |
thisArg? |
any |
An optional parameter which, when set, will be bound as the this context when the callback is called. Falsy values will be not be bound. |
void
onLoaded(): void;Defined in: ui/core/view-base/index.ts
void
onResumeNativeUpdates(): void;Defined in: ui/core/view-base/index.ts
void
onUnloaded(): void;Defined in: ui/core/view-base/index.ts
void
removeEventListener(
eventName: string,
callback?: (data: EventData) => void,
thisArg?: any): void;Defined in: data/observable/index.ts
Removes listener(s) for the specified event name.
| Parameter | Type | Description |
|---|---|---|
eventName |
string |
Name of the event to attach to. |
callback? |
(data: EventData) => void |
An optional parameter pointing to a specific listener. If not defined, all listeners for the event names will be removed. |
thisArg? |
any |
An optional parameter which when set will be used to refine search of the correct callback which will be removed as event listener. |
void
Observable.removeEventListener
requestLayout(): void;Defined in: ui/core/view-base/index.ts
Invalidates the layout of the view and triggers a new layout pass.
void
resetNativeView(): void;Defined in: ui/core/view-base/index.ts
Resets properties/listeners set to the native view.
void
set(name: string, value: any): void;Defined in: ui/core/view-base/index.ts
Updates the specified property with the provided value.
| Parameter | Type |
|---|---|
name |
string |
value |
any |
void
setInlineStyle(style: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
style |
string |
void
setNativeView(value: any): void;Defined in: ui/core/view-base/index.ts
Set the nativeView field performing extra checks and updates to the native properties on the new view. Use in cases where the createNativeView is not suitable. As an example use in item controls where the native parent view will create the native views for child items.
| Parameter | Type |
|---|---|
value |
any |
void
setProperty(name: string, value: any): void;Defined in: data/observable/index.ts
Updates the specified property with the provided value and raises a property change event and a specific change event based on the property name.
| Parameter | Type |
|---|---|
name |
string |
value |
any |
void
showModal(view: ViewBase, modalOptions?: ShowModalOptions): ViewBase;Defined in: ui/core/view-base/index.ts
Shows the view passed as parameter as a modal view.
| Parameter | Type | Description |
|---|---|---|
view |
ViewBase |
View instance to be shown modally. |
modalOptions? |
ShowModalOptions |
A ShowModalOptions instance |
ViewBase
showModal(moduleName: string, modalOptions?: ShowModalOptions): ViewBase;Defined in: ui/core/view-base/index.ts
Shows the View contained in moduleName as a modal view.
| Parameter | Type | Description |
|---|---|---|
moduleName |
string |
The name of the module to load starting from the application root. |
modalOptions? |
ShowModalOptions |
A ShowModalOptions instance |
ViewBase
toString(): string;Defined in: ui/core/view-base/index.ts
Returns a string representation of an object.
string
unbind(property: string): void;Defined in: ui/core/view-base/index.ts
| Parameter | Type |
|---|---|
property |
string |
void
unloadView(view: ViewBase): void;Defined in: ui/core/view-base/index.ts
Unload view.
| Parameter | Type | Description |
|---|---|---|
view |
ViewBase |
to unload. |
void
static addEventListener(
eventName: string,
callback: (data: EventData) => void,
thisArg?: any,
once?: boolean): void;Defined in: data/observable/index.ts
Please avoid using the static event-handling APIs as they will be removed in future.
| Parameter | Type |
|---|---|
eventName |
string |
callback |
(data: EventData) => void |
thisArg? |
any |
once? |
boolean |
void
static off(
eventName: string,
callback?: (data: EventData) => void,
thisArg?: any): void;Defined in: data/observable/index.ts
Please avoid using the static event-handling APIs as they will be removed in future.
| Parameter | Type |
|---|---|
eventName |
string |
callback? |
(data: EventData) => void |
thisArg? |
any |
void
static on(
eventName: string,
callback: (data: EventData) => void,
thisArg?: any,
once?: boolean): void;Defined in: data/observable/index.ts
Please avoid using the static event-handling APIs as they will be removed in future.
| Parameter | Type |
|---|---|
eventName |
string |
callback |
(data: EventData) => void |
thisArg? |
any |
once? |
boolean |
void
static once(
eventName: string,
callback: (data: EventData) => void,
thisArg?: any): void;Defined in: data/observable/index.ts
Please avoid using the static event-handling APIs as they will be removed in future.
| Parameter | Type |
|---|---|
eventName |
string |
callback |
(data: EventData) => void |
thisArg? |
any |
void
static removeEventListener(
eventName: string,
callback?: (data: EventData) => void,
thisArg?: any): void;Defined in: data/observable/index.ts
Please avoid using the static event-handling APIs as they will be removed in future.
| Parameter | Type |
|---|---|
eventName |
string |
callback? |
(data: EventData) => void |
thisArg? |
any |
void