import { concat } from "https://deno.land/x/aitertools@0.6.0/src/concat.ts";
Concatenates multiple async iterables into one async iterable.
import { concat } from "./concat.ts";
async function* gen() { yield "foo"; yield "bar"; yield "baz"; yield "qux" }
const iterable = concat(gen(), ["a", "b", "c", "d"]);
for await (const value of iterable) console.log(value);
The above example will print the following 8 lines:
foo
bar
baz
qux
a
b
c
d