Namespace goog.async.nextTick.<SCOPE>

code »

Fires the provided callbacks as soon as possible after the current JS execution context. setTimeout(…, 0) takes at least 4ms when called from within another setTimeout(…, 0) for legacy reasons. This will not schedule the callback as a microtask (i.e. a task that can preempt user input or networking callbacks). It is meant to emulate what setTimeout(_, 0) would do if it were not throttled. If you desire microtask behavior, use goog.Promise instead.

Main

<SCOPE> nextTick ( callback, opt_context )
Parameters
callback: function(this: SCOPE)
Callback function to fire as soon as possible.
opt_context: SCOPE=
Object in whose scope to call the listener.
Show:

Global Functions

Determines the best possible implementation to run a function as soon as the JS event loop is idle.

Returns
The "setImmediate" implementation.

Cache for the setImmediate implementation.

code »goog.async.nextTick.wrapCallback_ ( callback )function()

Helper function that is overrided to protect callbacks with entry point monitor if the application monitors entry points.

Parameters
callback: function()
Callback function to fire as soon as possible.
Returns
The wrapped callback.