Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

remark-math

Package Overview
Dependencies
Maintainers
2
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

remark-math

remark plugin to parse and stringify math

  • 2.0.0
  • Source
  • npm
  • Socket score

Version published
Maintainers
2
Created

What is remark-math?

The remark-math package is a plugin for the remark markdown processor that allows you to parse and render mathematical expressions written in LaTeX. It supports both inline and block math expressions, making it useful for documents that require mathematical notation.

What are remark-math's main functionalities?

Inline Math

This feature allows you to include inline mathematical expressions within your markdown text. The example demonstrates how to use the remark-math plugin to parse and render an inline math expression.

const remark = require('remark');
const remarkMath = require('remark-math');
const html = require('remark-html');

remark()
  .use(remarkMath)
  .use(html)
  .process('Here is some inline math: $E=mc^2$', function (err, file) {
    if (err) throw err;
    console.log(String(file));
  });

Block Math

This feature allows you to include block mathematical expressions in your markdown text. The example demonstrates how to use the remark-math plugin to parse and render a block math expression.

const remark = require('remark');
const remarkMath = require('remark-math');
const html = require('remark-html');

remark()
  .use(remarkMath)
  .use(html)
  .process('$$\int_0^\infty e^{-x} \, dx = 1$$', function (err, file) {
    if (err) throw err;
    console.log(String(file));
  });

Other packages similar to remark-math

Keywords

FAQs

Package last updated on 10 Sep 2019

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

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc