@innodoc/mathjax-num

0.0.3 • Public • Published

mathjax-num

A MathJax v3 extension that adds a \num command for printing a localized decimal marker.

Version License

Installation

Enable the extension by configuring MathJax appropriately, e.g.:

MathJax = {
   loader: {
      load: '[mathjaxnum]/num.min.js'],
      paths: {
        mathjaxnum: 'https://cdn.jsdelivr.net/npm/@innodoc/mathjax-num@latest/dist',
      },
   },
   tex: {
      packages: {
        '[+]': ['num'],
      },
   },
};

Usage

\num{3.5} (also \num{3,5}) can be used to render a decimal number with a localized decimal separator. The separator is determined by the html lang attribute.

Also, it is possible to output only the localized decimal marker by using the \decmarker command.

License

MIT

Package Sidebar

Install

npm i @innodoc/mathjax-num

Weekly Downloads

0

Version

0.0.3

License

MIT

Unpacked Size

16.7 kB

Total Files

6

Last publish

Collaborators

  • tumidi