{"repo":"syntax-tree/mdast-util-to-hast","free":true,"listed":false,"github":"https://github.com/syntax-tree/mdast-util-to-hast","clone":"git clone https://github.com/syntax-tree/mdast-util-to-hast.git","description":"utility to transform mdast to hast","language":"JavaScript","stars":123,"topics":["syntax-tree","mdast","hast","unist","hast-util","mdast-util","markdown","html"],"license":"MIT","category":"productivity","readme_excerpt":"mdast-util-to-hast [![Build][build-badge]][build] [![Coverage][coverage-badge]][coverage] [![Downloads][downloads-badge]][downloads] [![Size][size-badge]][size] [![Sponsors][sponsors-badge]][collective] [![Backers][backers-badge]][collective] [![Chat][chat-badge]][chat] [mdast][] utility to transform to [hast][]. Contents What is this? When should I use this? Install Use API defaultFootnoteBackContent(referenceIndex, rereferenceIndex) defaultFootnoteBackLabel(referenceIndex, rereferenceIndex) defaultHandlers [ toHast(tree[, options]) ](#tohasttree-options) FootnoteBackContentTemplate FootnoteBackLabelTemplate Handler Handlers Options Raw State Examples Example: supporting HTML in markdown naïvely Example: supporting HTML in markdown properly Example: footnotes in languages other than English Example: supporting custom nodes Algorithm Default handling Fields on nodes CSS Syntax tree Nodes Types Compatibility Security Related Contribute License What is this? This package is a utility that takes an [mdast][] (markdown) syntax tree as input and turns it into a [hast][] (HTML) syntax tree. When should I use this? This project is useful when you want to deal with ASTs and turn markdown to HTML. The hast utility [ hast-util-to-mdast ][hast-util-to-mdast] does the inverse of this utility. It turns HTML into markdown. The remark plugin [ remark-rehype ][remark-rehype] wraps this utility to also turn markdown to HTML at a higher-level (easier) abstraction. Install This package is [ESM ","default_branch":null,"files":null,"tree":[],"storefront":"/r/syntax-tree","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/syntax-tree/mdast-util-to-hast/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}