Docs (4.0.0)
class Activity method

createActiveTaskQueue

Creates a task queue that’s started, paused, resumed, and stopped automatically based on the state of this activity.

protected

protected createActiveTaskQueue(config?: ConfigOptions.Arg<AsyncTaskQueue.Options>): AsyncTaskQueue

Notes

  • Use this method to create an AsyncTaskQueue instance to run background tasks only while the activity is active, e.g. when the user is viewing a particular screen of the application.

Parameters

Return value

A new AsyncTaskQueue instance

Errors

  • This method throws an error if the activity has been unlinked.

Related

  • class ActivityA class that represents a part of the application that can be activated when the user navigates to it.