Effection Logo

function subscribe

thefrontside/effection

function subscribe<T, R>(iter: AsyncIterator<T, R>): Subscription<T, R>

Convert any AsyncIterator into an effection https://effection-www-s5a0jkwj0z5x.deno.dev/api/v4/Subscription

This allows you to consume any AsyncIterator as a https://effection-www-s5a0jkwj0z5x.deno.dev/api/v4/Subscription.

Type Parameters

T

R

Parameters

iter: AsyncIterator<T, R>

  • the iterator to convert

Return Type

https://effection-www-s5a0jkwj0z5x.deno.dev/api/v4/Subscription&lt;T, R>

a subscription that will produce each item of iter