New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

mathml2latex

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mathml2latex

Convert mathml to latex.

latest
Source
npmnpm
Version
1.1.3
Version published
Weekly downloads
573
24.3%
Maintainers
1
Weekly downloads
 
Created
Source

mathml2latex

It's a javascript library to convert mathML to latex

Build

Clone this repo and run npm run build, It'll generate belowing files:

lib
├── mathml2latex.browser.cjs.js
├── mathml2latex.browser.es.js
├── mathml2latex.browser.umd.js
├── mathml2latex.cjs.js
├── mathml2latex.es.js
└── mathml2latex.umd.js
dist
└── mathml2latex.js

usage

load library

In browser environment, you need to build the library first, then load it:

<script src="dist/mathml2latex.js"></script>

Using with npm

npm install mathml2latex
const MathMl2LaTeX = require('mathml2latex')

convert mathml html

const mathmlHtml = '<math display="block"><mfrac><mi>a</mi><mi>b</mi></mfrac></math>';
const latex = MathML2LaTeX.convert(mathmlHtml); // => \frac{a}{b}

Keywords

converter

FAQs

Package last updated on 29 Oct 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts