Invokes a function asynchronously. The context of the callback function is function is bound to 'this' automatically. Returns a handle which may be passed to cancelAsync to cancel the asynchronous call.
If you would prefer to run the callback after a given duration, see the asyncTimer method.
If you would like to cancel this, use cancelAsync.
int async(RequestAnimationFrameCallback method) {
// when polyfilling Object.observe, ensure changes
// propagate before executing the async method
scheduleMicrotask(Observable.dirtyCheck);
PolymerJs.flush(); // for polymer-js interop
return window.requestAnimationFrame(method);
}