Back to Explore

sindresorhus/is-stream

GitHub
1 watchersOpen source

Last release: 2/19/2024

is-stream is a Node.js utility that checks whether a value is a Node.js stream. It exports functions like isStream, isWritableStream, and isReadableStream to help you verify stream types before using them, with an option (checkOpen) to return false for already closed streams.

Project status

  • Actively maintained: Evidence of ongoing work includes a recent upstream push timestamp (2024-10-28), and the project had updates published in 2024 (v4.0.0 and v4.0.1).
  • Update cadence: There is a long gap between v3.0.0 (2021-08-10) and v4.0.0 (2024-02-19), followed by a near immediate follow-up update (v4.0.1 on 2024-02-19). No further published updates are shown in the provided history after v4.0.1.

AI summary generated Today

AI-generated from public sources. May be inaccurate. Report

Recent updates

  • v4.0.1

    2/19/2024

    v4.0.1 is described in the release notes only as a documentation fix. The actual diff shows no runtime implementation changes, only updates to the type declaration comments and README around the Options.checkOpen default.

  • v4.0.0

    2/19/2024

    v4.0.0 requires Node.js 18 and adds a new option to influence whether the utility checks that the provided stream is still open. It also broadens detection to support HTTP message/response stream instances.

    BreakingFeatures
  • v3.0.0

    8/10/2021

    v3.0.0 converts the package to pure ESM and replaces the previous default export pattern. The implementation was refactored from a single callable function with attached properties into separately exported named functions for checking writable, readable, duplex, and transform streams.

    Breaking
  • v2.0.1

    7/26/2021

    v2.0.1 makes a targeted change to `isStream.transform` detection. Release notes mention only this fix, but the diff also includes type-definition and test-related updates that could affect downstream TypeScript and stream classification expectations.

  • v2.0.0

    4/20/2019

    v2.0.0 introduces new TypeScript definitions for the package and raises the minimum supported Node.js version. The release includes a breaking change requiring Node.js 8, which may affect users on older runtimes.

    BreakingFeatures