Skip to content

Remove Banzai math filters and use native support

What does this MR do and why?

gitlab-glfm-markdown now supports parsing math syntax (both dollar and code/GitLab syntax) natively. This allows us to remove the Banzai math filters that attempted to implement this support.

We will still keep the old filters, disabled when using the new parser, so that we can do more performance testing.

Note that dollar math now uses span tags rather than code tags (thus the change in the code). This provides more compatibility with other parsers, as mentioned in https://github.com/kivikakk/comrak/pull/366#issuecomment-2016316394

This also fixes a huge list of bugs, see the related issues in #454565 (closed). A couple aren't fixed, but most are.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

How to set up and validate locally

  • in an issue description paste the following markdown and then preview it. You should see math displayed
$`2+2`$ + $3+3$ + $$4+4$$

$$
5+5
$$

```math
6+6
```

Related to #454565 (closed)

Edited by Brett Walker

Merge request reports

Loading