@sebastianowy/async-array
TypeScript icon, indicating that this package has built-in type declarations

1.1.1 • Public • Published

AsyncArray

Run array higher order functions asynchronously

npm latest version Build states semantic-release

Installation

npm install --save @sebastianowy/async-array
# or
yarn add @sebastianowy/async-array

Usage

Examples

  • async sorting
import { AsyncArray } from "@sebastianowy/async-array";

const array = [3, 5, 1, 2, 4];
const asyncArray = new AsyncArray(array);
asyncArray
  .sort((left, right) => Promise.resolve(left - right))
  .then(console.log);

will produce:

[1, 2, 3, 4, 5]

Package Sidebar

Install

npm i @sebastianowy/async-array

Weekly Downloads

0

Version

1.1.1

License

MIT

Unpacked Size

80.3 kB

Total Files

52

Last publish

Collaborators

  • sebastianowy.dev