# markdown-it-mathjax-svg

> Render Mathjax for makdown-it

Latest version **1.0.4** (published 2018-12-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install markdown-it-mathjax-svg
pnpm add markdown-it-mathjax-svg
yarn add markdown-it-mathjax-svg
bun add markdown-it-mathjax-svg
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.4 |
| Published | 2018-12-16 |
| First published | 2018-11-27 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 23.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Maintainers | swimmingwhale |
| Keywords | markdown, MathJax, math, LaTeX, markdown-it-plugin, markdown-it |

## Links

- npm: https://www.npmjs.com/package/markdown-it-mathjax-svg
- Repository: https://github.com/swimmingwhale/markdown-it-mathjax-svg
- Homepage: https://github.com/swimmingwhale/markdown-it-mathjax-svg#readme
- Issues: https://github.com/swimmingwhale/markdown-it-mathjax-svg/issues
- npm.io page: https://npm.io/package/markdown-it-mathjax-svg

## Alternatives

- [@mdxeditor/editor](https://npm.io/package/@mdxeditor/editor.md) — 962.4K weekly downloads
- [mmdb-lib](https://npm.io/package/mmdb-lib.md) — 680.9K weekly downloads
- [playcanvas](https://npm.io/package/playcanvas.md) — 36.2K weekly downloads
- [@glw907/cairn-cms](https://npm.io/package/@glw907/cairn-cms.md) — 967 weekly downloads
- [markdown-to-confluence](https://npm.io/package/markdown-to-confluence.md) — 103 weekly downloads

## Recent versions

- 1.0.4 (latest) — 2018-12-16
- 1.0.3 — 2018-11-28
- 1.0.2 — 2018-11-27
- 1.0.1 — 2018-11-27
- 1.0.0 — 2018-11-27

## README

# markdown-it-mathjax-svg

markdown-it plugins with mathjax. Rendering mathematical formulas using the server.

The mathjax rendering service use [mathjax-node](https://github.com/mathjax/mathjax-node) 

Install:
```
npm install markdown-it-mathjax-svg
```

Usage:
```
var config = {
    mathServiceUrl: 'http://mathServiceUrl?latex='
}

var mdmathjax = require('../index');
var markdown = require('markdown-it')()
    .use(mdmathjax, config);

var testLatex = '$$x_{ij }^2$$\n' +
    '$x_{ij }^2$\n' +
    'inline math $\\frac{1}{2}$ inline math\n';


console.log(markdown.render(testLatex))

output:
// <p><img src="http://mathServiceUrl?latex=x_%7Bij%20%7D%5E2%0A" svgimg="1"></p>
// <p><img src="http://mathServiceUrl?latex=x_%7Bij%20%7D%5E2" svgimg="1">
// inline math <img src="http://mathServiceUrl?latex=%5Cfrac%7B1%7D%7B2%7D" svgimg="1"> inline math</p>
```

---
_Source: https://npm.io/package/markdown-it-mathjax-svg · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
