10000 MathJax / LaTeX support · Issue #4589 · wekan/wekan · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

MathJax / LaTeX support #4589

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

Closed
7 of 8 tasks
lstngr opened this issue Jul 13, 2022 · 0 comments
Closed
7 of 8 tasks

MathJax / LaTeX support #4589

lstngr opened this issue Jul 13, 2022 · 0 comments

Comments

@lstngr
Copy link
lstngr commented Jul 13, 2022

Issue

Server Setup Information

  • Did you test in newest Wekan?: Testing in v6.30
  • Did you configure root-url correctly so Wekan cards open correctly (see https://github.com/wekan/wekan/wiki/Settings)?
  • Operating System: Linux
  • Deployment Method (Snap/Docker/Sandstorm/bundle/source): Docker
  • Http frontend if any (Caddy, Nginx, Apache, see config examples from Wekan GitHub wiki first):
  • Node.js Version: v14.20.0
  • MongoDB Version: v5.0.9
  • What webbrowser version are you using (Wekan should work on all modern browsers that support Javascript)? Firefox 102.0.1

Problem description

I've installed a personal instance of Wekan for work and find it very useful. However, I often need to typeset formulas with LaTeX and found out that markdown-it does not support it natively. To my surprise, I could not find any related discussion in this repository.

I'm not familiar at all with Javascript and the many frameworks used in Wekan, but I found the simpler solution to be to add the markdown-it-mathjax3 package and register it as a plugin for markdown-it.
See this commit for a diff.

The result is that all fields processed by markdown-it apparently support LaTeX, (I haven't set the local, don't pay attention to the placeholder strings in the UI)

image

I wanted to know if this feature sparked interest in the Wekan community before jumping to the "pull request" button.
A few thoughts / issues you may find relevant:

  • markdown-it-mathjax3 relies on mathjax-full, which renders LaTeX locally (no CDN / internet connectivity required)
  • LaTeX formatting will be enabled whenever the Markdown formatter is called. MathJax inserts svg tags in those places, I'm not sure if there's any part of Wekan where this behavior is undesired, or that svg tags could break.
  • There is no way to enable/disable this plugin easily (at least that I know of, my js-fu is very limited)
  • I only managed to build through Docker containers and docker-compose on Linux (whether talking about master or my branch). I did not update rebuild_wekan.sh.

I'm open to any feedback and would love to see this functionality merged at some point in the future.
And thank you again for Wekan, loving it so far!

Reproduction Steps

Not applicable

Logs

Not applicable

@xet7 xet7 closed this as completed in e819001 Jul 13, 2022
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
0