Socket
Socket
Sign inDemoInstall

math-api

Package Overview
Dependencies
8
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    math-api

math.now.sh API ported as a npm package


Version published
Weekly downloads
3
decreased by-25%
Maintainers
1
Install size
38.8 MB
Created
Weekly downloads
 

Readme

Source

Math API

You want to include Latex based equations on your website? Check out this awesome API 👉 https://math.now.sh

But sometimes, you might want to create those images locally. That's why this package is created.

Installation

npm install math-api

Usage

const math = require("math-api");

const svgImageContent = math.renderLatex({
	// required
	content: "\\log\\prod^N_{i}x_{i}=\\sum^N_i\\log{x_i}",

	// optional (default values are shown here)
	mode: "block", // or "inline"
	color: "black",
});

// inline svgImageContent in your html
// or
// write it to a svg file

Keywords

FAQs

Last updated on 15 Sep 2021

Did you know?

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc