Windows Dev Center

observableMixin.bind method

Applies to Windows and Windows Phone

Links the specified action to the property specified in the name parameter. This function is invoked when the value of the property may have changed. It is not guaranteed that the action will be called only when a value has actually changed, nor is it guaranteed that the action will be called for every value change. The implementation of this function coalesces change notifications, such that multiple updates to a property value may result in only a single call to the specified action.

Syntax


var object = observableMixin.bind(name, action);

Parameters

name

Type: String

The name of the property to which to bind the action.

action

Type: Function

The function to invoke asynchronously when the property may have changed.

Return value

Type: Object

A reference to this observableMixin object.

Requirements

Minimum supported client

Windows 8 [Windows Store apps only]

Minimum supported server

Windows Server 2012 [Windows Store apps only]

Minimum supported phone

Windows Phone 8.1

Namespace

WinJS.Binding

Library

Winjs.js

See also

observableMixin

 

 

Show:
© 2015 Microsoft