Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Is this alternative way to set global LaTeX macros possible? #290

Open
MrOddlyFormal opened this issue Mar 7, 2023 · 0 comments

Comments

@MrOddlyFormal
Copy link

I'm trying to set a \let-type global macro, like they're discussing here. For \def macros I've been using the katex_config.js file, but KaTeX does not yet support the equivalent of \let through the macros object.
KaTeX does support the following syntax:

const macros = {}
katex.renderToString(content, {macros, globalGroup: true})

And this function is what mume uses.

Mume lets us edit the macros object, but I'm looking for a way to modify content. Is it possible? Maybe in the parser.js file?

Ideally, Mume should use a regular macros.tex file for global macros, and content would be populated by it during the call to KaTeX with globalGroup: true. This way users would not have to keep two files for the same thing.

Thanks for the help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant