-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
backtick math #27602
Comments
I see there is some discussion on this on the corresponding PR from Sep 2022. One of the participants repeats some points I've made concerning the GitHub $-math implementation (see here). GitHub struggles with their math implementation to this day (see here), but Gitea got many things right straight away. Great! Still, I believe using the $-syntax is a mistake; you'll always find yourself fighting with Markdown, and things like
will probably never render correctly. (LaTeX has The $`n`$th apple costs $$`(n+1)`$. The Using backticks plays nicely with Markdown and avoids all kinds of problems. And this doesn't mention the straightforward implementation of it. |
These mathblocks exist for gitea, does this help?
|
@eeyrjmr Sorry for not being clear enough. These don't help at all, no, and that's what I'm trying to say. Markdown interferes with this syntax and will never be reliable. Edit: Maybe Edit:: This syntax looks a little weird: \[
\begin{align*}
a = b
\end{align*}
\] |
It's supported now. |
Feature Description
GitLab and GitHub both have support for backtick math, i.e.,
The Pythagorean theorem can be written as an equation relating the lengths of the sides$a$ , $b$ and the hypotenuse $c$ :
The backticks avoid problems with accidental markdown sanitation in math content (which causes many problems for GitHub). The backticks suggests to the sanitizer that this is "code", not be touched.
GitLab started out with only the backticked mode in 2016. (They've added an imperfect dollar mode now.)
Right now, Gitea has no proper support for backticked math. Inline backticks
are literally rendered as backticks,
and display-block backticks are rendered, but not centralized:
Using backticks in math also has the advantage that other Markdown software, e.g., linters or formatters, can be run on the file without modification.
It'd be great if Gitea could support backticked math as well.
Edit: I've surveyed math syntaxes and performance on GitHub, Gitea, GitLab.. Gitea's bracket-syntax is unique and hence not compatible. The backticked syntax is sorely missing from Gitea, especially given its great performance on the other platforms.
The text was updated successfully, but these errors were encountered: