# @svgr/hast-util-to-babel-ast

> Transform HAST to Babel AST (JSX)

Latest version **8.0.0** (published 2023-05-09) · MIT license · 0 weekly downloads

## Install

```sh
npm install @svgr/hast-util-to-babel-ast
pnpm add @svgr/hast-util-to-babel-ast
yarn add @svgr/hast-util-to-babel-ast
bun add @svgr/hast-util-to-babel-ast
```

## Health

**Score 40/100 (D)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; popular repo.

Warnings: low downloads.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 8.0.0 |
| Published | 2023-05-09 |
| First published | 2018-11-04 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=14 |
| Dependencies | 2 |
| Unpacked size | 71.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 11059 |
| Author | Greg Bergé |
| Maintainers | neoziro |
| Keywords | html, hast, babel, hast-util, unist-util, unist |

## Links

- npm: https://www.npmjs.com/package/@svgr/hast-util-to-babel-ast
- Repository: https://github.com/gregberge/svgr.git#main
- Homepage: https://react-svgr.com
- Issues: https://github.com/gregberge/svgr/issues
- Funding: https://github.com/sponsors/gregberge
- npm.io page: https://npm.io/package/@svgr/hast-util-to-babel-ast

## Dependencies (2)

- [entities](https://npm.io/package/entities.md) ^4.4.0
- [@babel/types](https://npm.io/package/@babel/types.md) ^7.21.3

## Alternatives

- [@tsparticles/shape-image](https://npm.io/package/@tsparticles/shape-image.md) — 303.7K weekly downloads
- [@tsparticles/shape-line](https://npm.io/package/@tsparticles/shape-line.md) — 233.7K weekly downloads
- [stringify-attributes](https://npm.io/package/stringify-attributes.md) — 58.6K weekly downloads
- [mobile-drag-drop](https://npm.io/package/mobile-drag-drop.md) — 46.3K weekly downloads
- [@comunica/actor-rdf-parse-html](https://npm.io/package/@comunica/actor-rdf-parse-html.md) — 29.2K weekly downloads

## Recent versions

- 8.0.0 (latest) — 2023-05-09
- 6.0.0-alpha.3 (next) — 2021-11-12
- 7.0.0 — 2023-03-24
- 6.5.1 — 2022-10-27
- 6.5.0 — 2022-10-14
- 6.4.0 — 2022-10-01
- 6.3.1 — 2022-07-22
- 6.3.0 — 2022-07-18
- 6.2.1 — 2022-01-30
- 6.0.0 — 2021-11-28
- 6.0.0-alpha.1 — 2021-10-31
- 6.0.0-alpha.0 — 2021-09-24
- 5.5.0 — 2020-11-15
- 5.4.0 — 2020-04-27
- 5.0.1 — 2019-12-29
- … 9 more at https://npm.io/package/@svgr/hast-util-to-babel-ast/versions

## README

# @svgr/hast-util-to-babel-ast

[![Build Status](https://img.shields.io/travis/smooth-code/svgr.svg)](https://travis-ci.org/smooth-code/svgr)
[![Version](https://img.shields.io/npm/v/@svgr/hast-util-to-babel-ast.svg)](https://www.npmjs.com/package/@svgr/hast-util-to-babel-ast)
[![MIT License](https://img.shields.io/npm/l/@svgr/hast-util-to-babel-ast.svg)](https://github.com/smooth-code/svgr/blob/master/LICENSE)

Transforms HAST into Babel AST.

## Install

```
npm install --save-dev @svgr/hast-util-to-babel-ast
```

## Usage

```js
import { parse } from 'svg-parser'
import hastToBabelAst from '@svgr/hast-util-to-babel-ast'

const hastTree = parse(`<svg></svg>`)

const babelTree = hastToBabelAst(hastTree)
```

## License

MIT

---
_Source: https://npm.io/package/@svgr/hast-util-to-babel-ast · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
