
Security News
PEP 810 Proposes Explicit Lazy Imports for Python 3.15
An opt-in lazy import keyword aims to speed up Python startups, especially CLIs, without the ecosystem-wide risks that sank PEP 690.
@amermathsoc/mathjax-href
Advanced tools
A custom href extension for MathJax's TeX input
xhref.js
This extension implements a TeX macro \xhref
.
\xhref[type]{url}{content}
In the output, this will generate <a href="url" data-ams-ref="type">content</a>
with 5px
padding.
This macro integrates with AmerMathSoc/texml-to-html; see its documentation for more information on data-ams-ref
.
For example, install @mathjax/src
and @amermathsoc/mathjax-xhref
and use something like
import { TeX } from "@mathjax/src/js/input/tex.js";
import { configuration as xhref } from "mathjax-xhref";
const tex = new TeX({
packages: [xhref.name],
textmacros: {
packages: { "[+]": [xhref.name] },
},
});
Note: the textmacros
part allows the use of this macro in text-mode.
For client-side use, you need load browser/xhref.js
, e.g., from a CDN.
Follow the instructions from the MathJax documentation on loading a third-party extensions, e.g.,
MathJax = {
loader: {
load: ["[xhref]/xhref.js"],
paths: {
xhref:
"https://cdn.jsdelivr.net/npm/@amermathsoc/mathjax-xhref@3/browser",
},
},
tex: {
packages: { "[+]": ["xhref"] },
textmacros: {
packages: { "[+]": ["xhref"] },
},
},
};
FAQs
A custom href extension for MathJax's TeX input
We found that @amermathsoc/mathjax-href demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
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.
Security News
An opt-in lazy import keyword aims to speed up Python startups, especially CLIs, without the ecosystem-wide risks that sank PEP 690.
Security News
Socket CEO Feross Aboukhadijeh discusses the recent npm supply chain attacks on PodRocket, covering novel attack vectors and how developers can protect themselves.
Security News
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.