RequestQueue class


A queue that can be used to queue up requests.

Signature:

export declare class RequestQueue 

Constructor

new RequestQueue ()

Constructs a new instance of the RequestQueue class.

Parameters:

ParameterTypeDescription

Methods

.dequeue ()

Dequeues the first action to be executed.

Signature:

dequeue(): Promise<boolean>;

Return type: Promise < Boolean >


.enqueue ()

Enqueues an action to be executed.

Signature:

enqueue(action: () => Promise<AxiosResponse>): Promise<AxiosResponse<any, any>>;

Parameters:

ParameterTypeDescription
action() = > Promise < AxiosResponse >The action to execute.

Return type: Promise < AxiosResponse < any, any > >


Table of Contents