Skip to content

Latest commit

 

History

History
25 lines (14 loc) · 933 Bytes

File metadata and controls

25 lines (14 loc) · 933 Bytes

{% if book.isPdf %}

toAsync

{% else %}

{% endif %}

Converts the function into an asynchronous function. Each invocation of the resulting asynchronous function causes an invocation of the original synchronous function on the specified scheduler.

Arguments

  1. func (Function): Function to convert to an asynchronous function.
  2. [scheduler=Rx.Scheduler.timeout] (Scheduler): Scheduler to run the function on. If not specified, defaults to Scheduler.timeout.
  3. [context] (Any): The context for the func parameter to be executed. If not specified, defaults to undefined.

Returns

(Function): Asynchronous function.

Example