# @esfx/iter-fn

> An fp-style iteration API for ECMAScript iterables.

Latest version **1.0.2** (published 2022-11-01) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @esfx/iter-fn
pnpm add @esfx/iter-fn
yarn add @esfx/iter-fn
bun add @esfx/iter-fn
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2022-11-01 |
| First published | 2020-12-18 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 12 |
| Unpacked size | 745.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 234 |
| Author | Ron Buckton |
| Maintainers | rbuckton |

## Links

- npm: https://www.npmjs.com/package/@esfx/iter-fn
- Repository: https://github.com/esfx/esfx
- Homepage: https://github.com/esfx/esfx#readme
- Issues: https://github.com/esfx/esfx/issues
- npm.io page: https://npm.io/package/@esfx/iter-fn

## Dependencies (12)

- [tslib](https://npm.io/package/tslib.md) ^2.4.0
- [@esfx/fn](https://npm.io/package/@esfx/fn.md) ^1.0.2
- [@esfx/interval](https://npm.io/package/@esfx/interval.md) ^1.0.2
- [@esfx/equatable](https://npm.io/package/@esfx/equatable.md) ^1.0.2
- [@esfx/iter-page](https://npm.io/package/@esfx/iter-page.md) ^1.0.2
- [@esfx/iter-lookup](https://npm.io/package/@esfx/iter-lookup.md) ^1.0.2
- [@esfx/iter-ordered](https://npm.io/package/@esfx/iter-ordered.md) ^1.0.2
- [@esfx/iter-grouping](https://npm.io/package/@esfx/iter-grouping.md) ^1.0.2
- [@esfx/iter-hierarchy](https://npm.io/package/@esfx/iter-hierarchy.md) ^1.0.2
- [@esfx/collection-core](https://npm.io/package/@esfx/collection-core.md) ^1.0.0
- [@esfx/collections-hashmap](https://npm.io/package/@esfx/collections-hashmap.md) ^1.0.2
- [@esfx/collections-hashset](https://npm.io/package/@esfx/collections-hashset.md) ^1.0.2

## Recent versions

- 1.0.2 (latest) — 2022-11-01
- 1.1.0-alpha.202307260322 (next) — 2023-07-26
- 1.0.0-dev.8 (dev) — 2022-10-20
- 1.1.0-alpha.202306080253 — 2023-06-08
- 1.1.0-alpha.202306061406 — 2023-06-06
- 1.1.0-alpha.202306061316 — 2023-06-06
- 1.1.0-alpha.202306051228 — 2023-06-05
- 1.1.0-alpha.202305082104 — 2023-05-08
- 1.1.0-alpha.202302091715 — 2023-02-09
- 1.1.0-alpha.202302071935 — 2023-02-07
- 1.1.0-alpha.202211291446 — 2022-11-29
- 1.1.0-alpha.202211221509 — 2022-11-22
- 1.0.1 — 2022-11-01
- 1.1.0-alpha.202210252139 — 2022-10-25
- 1.0.0 — 2022-10-20
- … 28 more at https://npm.io/package/@esfx/iter-fn/versions

## README

# `@esfx/iter-fn`

An iteration API for ECMAScript iterables.

# Overview

* [Installation](#installation)
* [Usage](#usage)
* [API](#api)

# Installation

```sh
npm i @esfx/iter-fn
```

# Usage

```ts
import { map, filter } from "@esfx/iter-fn";

// nested
const computerIsbns = map(filter(books, book => book.categories.includes("computers")), book => book.isbn);

// or, pipe-like
let _;
const computerIsbns = (
    _= books,
    _= filter(_, book => book.categories.includes("computers")),
    _= map(_, book => book.isbn),
    _);

// or, with actual pipes (if you are using a transpiler with support for Hack-style)
const computerIsbns = books
    |> filter(%, book => book.categories.includes("computers")),
    |> map(%, book => book.isbn);
```

# API

You can read more about the API [here](https://esfx.github.io/esfx/api/iter-fn.html).

---
_Source: https://npm.io/package/@esfx/iter-fn · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
