An open API service indexing awesome lists of open source software.

https://github.com/zebp/iterext

Ports of Rust's Iterator and future-rs' StreamExt
https://github.com/zebp/iterext

Last synced: about 2 months ago
JSON representation

Ports of Rust's Iterator and future-rs' StreamExt

Awesome Lists containing this project

README

        

# iterext

Approximate ports of
[Rust's Iterator](https://doc.rust-lang.org/stable/std/iter/trait.Iterator.html)
and
[future-rs' StreamExt](https://docs.rs/futures/0.3.15/futures/stream/trait.StreamExt.html)
to TypeScript.

## Example

```ts
import { Iter } from "./mod.ts";

Iter.repeatWith((i) => "A".repeat(i + 1))
.enumerate()
.map(([index, value]) => `[${index}] ${value}`)
.take(100)
.forEach(console.log);
```