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
- Host: GitHub
- URL: https://github.com/zebp/iterext
- Owner: zebp
- License: mit
- Created: 2021-06-05T16:22:32.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2021-12-13T22:44:12.000Z (over 3 years ago)
- Last Synced: 2025-04-02T05:49:34.264Z (about 2 months ago)
- Language: TypeScript
- Size: 36.1 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
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);
```