IdliQueue()

a queue system to utilize browser idle time to run tasks.

new IdliQueue()

Methods

clearPendingTasks()

Clears all pending tasks for the queue and stops any scheduled tasks from running.

destroy()

Destroys the instance by unregistering all added event listeners and removing any overridden methods.

getState() → {Object}

Returns the state object for the currently running task. If no task is running, null is returned.
Returns:
Object

hasPendingTasks() → {boolean}

Returns:
boolean

pushTask(…args)

Parameters:
Name Type Attributes Description
args * <repeatable>

runTasksImmediately()

Runs all scheduled tasks synchronously.

unshiftTask(…args)

Parameters:
Name Type Attributes Description
args * <repeatable>