JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 176395
  • Score
    100M100P100Q161019F
  • License ISC

Empties an async iterator

Package Exports

  • it-drain

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (it-drain) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

it-drain

Build status Coverage Status Dependencies Status

Drains an async iterator without returning anything

Mostly useful for tests or when you want to be explicit about consuming an iterable without doing anything with any yielded values.

Install

$ npm install --save it-drain

Usage

const drain = require('it-drain')

// This can also be an iterator, async iterator, generator, etc
const values = [0, 1, 2, 3, 4]

await drain(values)