Back to Explore

syntax-tree/unist-util-is

GitHub
2 watchersOpen source

Last release:

unist-util-is is a small utility for checking whether a UNIST node matches a given test, such as a specific node type or a set of required properties. It’s useful for avoiding repeated node-type and structure checks when working with syntax trees.

Project status

  • Maintenance status: The source appears actively maintained, with an updates push on 2025-10-22 and a latest published update (6.0.1) on 2025-10-16, which is within the last year of today (2026-06-09).
  • Update cadence: Updates are infrequent but ongoing. After a major update in 2023 (6.0.0), there was a follow-up in 2025 (6.0.1), suggesting a cadence of multi-year major changes and occasional patch/typing improvements rather than frequent releases.

AI summary generated

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

Recent updates

  • 6.0.1

    Release 6.0.1 primarily improves the TypeScript typings of `unist-util-is` to accept `ReadonlyArray` in test conditions. The diff also shows packaging, build, and CI/tooling changes that are not mentioned in the release notes.

    Features
  • 6.0.0

    unist-util-is 6.0.0 is a major release that modernizes the type system, renames several exported type aliases, and changes the package entrypoint via an export map. It also raises the minimum supported Node.js version to 16. The code changes go beyond the release notes mainly in how the package is declared to Node and how TypeScript types are expected to resolve.

    Breaking
  • 5.2.1

    Release 5.2.1 mainly updates the package manifest. The documented change is adding @types/unist to the dependencies.

  • 5.2.0

    Release 5.2.0 primarily documents an added TypeScript export, `PredicateTest`, and includes miscellaneous documentation and tsconfig updates. The code diff, however, shows a large internal refactor (moving implementation and JSDoc type definitions into a new `lib/` module) plus substantial build, tooling, and dev dependency changes not called out in the release notes.

    Features
  • 5.1.1

    Release 5.1.1 is presented as a type-only fix, specifically updating typings to allow `null`. The code diff shows additional runtime and tooling-related changes beyond the documented type tweak.

  • 5.1.0

    Release 5.1.0 introduces a new `Test` type alias in the TypeScript definitions. It also updates the `test` parameter typings for `is` and `convert` to reference this new alias, with no apparent runtime logic changes.

    Features
  • 5.0.0

    v5.0.0 is a major refactor that switches the package to ESM and replaces the hand-authored TypeScript declaration files with JSDoc-based type definitions generated from the source. The runtime entrypoint also changes how exports are exposed and how the `convert` utility is surfaced to consumers.

    BreakingFeatures
  • 4.1.0

    Release 4.1.0 focuses on TypeScript typing updates for `unist-util-is`. It expands the `test` parameter types to support nullish values and updates the documented behavior accordingly.

    Features
  • 4.0.4

    Release 4.0.4 is a small patch focused on making `convert` reliably return boolean values instead of sometimes returning `undefined`. In addition to that runtime behavior fix, the repo updates CI configuration, build script flags, and a dev lint dependency.

  • 4.0.3

    Release 4.0.3 is a small internal refactor described as improving bundle size. The code changes actually touch core validation and predicate conversion logic, including error behavior and the return values of predicate functions produced by `is.convert`.