Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

extractLast

import { extractLast } from "https://raw.githubusercontent.com/surma/observables-with-streams/28c55be6d855780c677fd1f4ba975f4d3144891d/src/index.ts";

Resolves with the last element emitted by the observable. If no items are emitted the promise is rejected.

async function extractLast<T>(o: Observable<T>): Promise<T>;
§
extractLast<T>(o: Observable<T>): Promise<T>
[src]

§Type Parameters

§Parameters

§

Observable to extract from.

§Return Type

§
Promise<T>
[src]

Promise that resolves with a single item.