Socket
Socket
Sign inDemoInstall

mathlive

Package Overview
Dependencies
Maintainers
1
Versions
171
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mathlive

Render and edit beautifully typeset math


Version published
Weekly downloads
51K
decreased by-34.14%
Maintainers
1
Weekly downloads
 
Created
Source

math live

Screenshot

MathLive: A Web Component for Math Input

  • A Web Component easy to integrate in your project, regardless of the framework you use (or even if you use no framework)
  • Beautiful, TeX-quality typesetting
  • Easy to use interface for formula editing
  • Designed for mobile devices with an extensive set of virtual keyboards
  • Accessility support: screen reader compatible, and includes custom math-to-speech support
  • Outputs LaTeX, MathML and MathJSON (Abstract Syntax Tree)
  • And it is easy to customize to your needs!

Maintenance GitHub license Build Status David

See cortexjs.io for more info or try it at mathlive.io

The popover panel A Virtual Keyboard
The Loop Equation

Using MathLive

Editing Math

To add a mathfield element in your page use a <math-field> tag. It works just like a <textarea> or <button>. You can manipulate the mathfield using methods of the element and listen for events to be notified when its internal state changes.

<!DOCTYPE html>
<html lang="en-US">
    <body>
        <math-field>f(x)=</math-field>
        <script src="https://unpkg.com/mathlive/dist/mathlive.min.js"></script>
    </body>
</html>

Displaying Static Math

Render static math equations by adding two lines to your web page.

<!DOCTYPE html>
<html lang="en-US">
    <body>
        <h1>Euler's Identity</h1>
        <p>$$e^{i\pi} + 1 = 0$$</p>

        <script type="module">
            import { renderMathInDocument } from 'https://unpkg.com/mathlive/dist/mathlive.min.mjs';
            renderMathInDocument();
        </script>
    </body>
</html>

Want to Help?

  • Using MathLive in your project? Want to support the project ongoing maintenance? Consider making a donation with PayPal
  • Something wrong? Got ideas for new features? Write up an issue. Read about Contributing and follow our Code of Conduct
  • Want to contribute some code for an issue or a feature? Read the Contributor Guide and the docs. Looking for inspiration? Pick one of the good first issues

More Questions?

License

This project is licensed under the MIT License.

Keywords

FAQs

Package last updated on 04 Nov 2020

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