Back to Explore

syntax-tree/mdast-util-to-hast

GitHub
1 watchersOpen source

Last release: 6 months ago

`mdast-util-to-hast` is a utility that converts an mdast (Markdown AST) input syntax tree into a hast (HTML AST) syntax tree. It is useful when you want to work with ASTs and turn parsed markdown structures into an HTML-oriented tree structure for further processing.

Project status

  • This source appears actively maintained, with an upstream push and published update as recently as 2025-11-23 (v13.2.1), after prior updates in 2024.
  • The update cadence from the available history is low but ongoing, with v13.2.0 on 2024-06-07 and v13.2.1 on 2025-11-23 (about 17 months), suggesting periodic maintenance rather than frequent churn.

AI summary generated Today

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

Recent updates

  • 13.2.1

    6 months ago

    Release 13.2.1 mainly addresses how `code` blocks with `lang` values containing spaces are converted into `className` values in the generated HAST. It also refactors JSDoc typing to use `@import` syntax and enables TypeScript declaration map generation.

  • 13.2.0

    6/7/2024

    Version 13.2.0 adds TypeScript typings so hast `ElementData` can include a `meta` field (intended for `data.meta` when converting from mdast to hast). The remaining changes are mostly internal refactors plus tooling and dependency upgrades.

    Features
  • 13.1.0

    1/11/2024

    Release 13.1.0 adds support for passing a `file` (a `VFile`) through the `toHast` options so handlers can reference the originating virtual file. The change is reflected in the TypeScript/JSDoc types, README configuration docs, and a new test that validates message emission via the provided `VFile`.

    Features