npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

edicuatex

v1.5.5

Published

Visual LaTeX equation editor for eXeLearning, Moodle and any web page

Readme

Versión en español

Online $\LaTeX$ Equation Editor

AGPL v3 CC BY-SA 4.0

Description

This project is a free tool designed to help teachers and students create and edit mathematical formulas easily, without needing in-depth knowledge of LaTeX. It allows you to generate educational materials with clear, professional mathematical notation. It can be used with programs that support LaTeX, such as eXeLearning, Moodle, Overleaf, etc.

The program works both as a standalone application and integrated into eXeLearning. When it detects it was opened from eXe (via a plugin for TinyMCE), a button appears to insert the formula directly. If opened standalone (e.g., in a browser), this button does not appear.


Integration with other web apps (postMessage)

Besides the eXeLearning/TinyMCE integration, you can integrate EdiCuaTeX into any website via postMessage without modifying your app:

  • Open the editor with parameters: append ?pm=1&origin=<YOUR_ORIGIN> to the editor URL.
    • Local example (popup): http://localhost:8000/index.html?pm=1&origin=http%3A%2F%2Flocalhost%3A8001
    • Public example (GitHub Pages): https://jjdeharo.github.io/edicuatex/index.html?pm=1&origin=https%3A%2F%2Fjjdeharo.github.io
    • origin must be the exact origin (protocol + host + port) of your receiving app.
  • Contextual button: with pm=1, a “Send to host” button appears.
  • Payload sent when clicking “Send”:
    • type: 'edicuatex:result'
    • latex: LaTeX code without delimiters
    • delimiter: value from the delimiter selector (none, parentheses, brackets, double_dollar, single_dollar)
    • wrapped: LaTeX including the selected delimiters

Minimal host example (popup or iframe):

<button id="open">Open editor</button>
<textarea id="out" rows="6" cols="60"></textarea>
<script>
let editorOrigin = '';
document.getElementById('open').onclick = () => {
  const url = 'http://localhost:8000/index.html?pm=1&origin=' + encodeURIComponent(location.origin);
  editorOrigin = new URL(url).origin; // e.g., http://localhost:8000
  window.open(url, 'edicuatex', 'width=1100,height=800');
};
window.addEventListener('message', (e) => {
  if (!editorOrigin || e.origin !== editorOrigin) return; // accept only from editor
  if (e.data && e.data.type === 'edicuatex:result') {
    document.getElementById('out').value = e.data.wrapped || e.data.latex || '';
  }
});
</script>

Notes

  • Works with both window.open (popup) and <iframe> embeds.
  • The eXe/TinyMCE integration remains intact and separate; the “Insert” button is shown only inside eXe.

1. index.html → Visual LaTeX Formula Editor

Main Features

  • Write formulas using a visual menu with customizable buttons and categories.
  • Preview the formula in real time thanks to MathJax.
  • Copy the LaTeX code ready to use, with or without delimiters.
  • Export the formula as a PNG image.
  • Search by name or code (e.g., square root, \int...).
  • Quick access to recently used formulas.
  • AI assistant to generate formulas from a description.
  • Support for multiple menus from local files, external URLs, or GitHub.
  • Automatically loads menus defined in menus/menus.json, with visible descriptions.

How to Use

  1. Select a formula or write code manually.
  2. Preview the result.
  3. Copy the code, download it as an image, or insert it directly into eXeLearning.

2. menus/editor.html → Visual Menu Editor for Formulas

This file allows you to create or modify collections of buttons with LaTeX formulas organized by category.

Main Features

  • Create, edit, and organize formula menus without manually writing JSON.
  • Use drag and drop to rearrange buttons.
  • AI assistant to generate elements, categories, or entire files.
  • Export menus in JSON format for use in index.html.
  • Load .json files from your computer, clipboard, or external URLs (like GitHub Raw).

Formula Menus (.json)

Menus define buttons organized in categories with LaTeX formulas. They can be loaded from index.html or created with menus/editor.html.

The default base menu is menus/base.json, which loads automatically when the editor opens. You can add more from the "Manage Menus" window.

Manifest menus/menus.json

The menus/menus.json file acts as an index of the available menus for the editor. It contains an array called menus, where each element specifies:

  • file: name of the .json file containing the categories and formulas.
  • description: text describing the menu's content (shown in the interface).

Example:

{
  "menus": [
    { "file": "base.json",       "description": "Basic Symbols" },
    { "file": "entornos.json",   "description": "Mathematical Environments" },
    { "file": "estadistica.json","description": "Statistics" },
    { "file": "fisica.json",     "description": "Physics" },
    { "file": "geometria.json",  "description": "Geometry" }
  ]
}

Structure of a Menu File

{
  "categorias": [
    {
      "nombre": "Algebra",
      "id": "algebra",
      "grid_template_columns": "repeat(auto-fit, minmax(80px, 1fr))",
      "isCollapsed": false,
      "elementos": [
        {
          "type": "button",
          "latex": "\\frac{a}{b}",
          "display": "\\frac{a}{b}",
          "title": "Fraction"
        },
        {
          "type": "custom_matrix",
          "title": "Custom Matrix"
        }
      ]
    }
  ]
}

MathJax

MathJax is served from this repository, under js/mathjax/. Nothing is fetched from a CDN, so the editor makes no third-party request, works on an intranet or an offline machine, and runs under a CSP that allows no external origins. Clone and serve: there is no build step and nothing to configure.

The directory holds the SVG path only (~18 MB): the bundle, the TeX extensions, the glyph ranges MathJax 4 fetches on demand, and the accessibility engine with speech rules for several languages. None of the accessibility payload is downloaded unless a reader opens MathJax's accessibility menu.

To upgrade, change the versions in package.json, keep the CDN fallback URL in js/edicuatex-tools.js on the same one, and regenerate the directory:

npm install
npm run vendor

Install from npm

The editor is published as edicuatex, so a site that embeds it can pin a version instead of copying files by hand:

npm install edicuatex

Serve node_modules/edicuatex/ as static files and open index.html. It is the same tree as this repository; MathJax is not in the package, and the pages get it from the CDN unless you also run npm run vendor (see above).

Releases are cut by pushing a tag: git tag v1.5.0 && git push origin v1.5.0.


License

  • Code: GNU AGPL v3. See LICENSE.txt.
  • Content (texts, screenshots, menu data): CC BY-SA 4.0.
    • https://creativecommons.org/licenses/by-sa/4.0/

Third-party libraries remain under their own licenses.


Author: Juan José de Haro
https://bilateria.org


Third-party libraries

EdiCuaTeX includes DOMPurify, a DOM-only XSS sanitizer for HTML, MathML and SVG.

DOMPurify details:

Copyright 2025 Dr.-Ing. Mario Heiderich, Cure53

DOMPurify is free software; you can redistribute it and/or modify it under the terms of either:

a) the Apache License Version 2.0, or b) the Mozilla Public License Version 2.0

See https://github.com/cure53/DOMPurify for more details.