You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[quote]It costs a lot of money for Soldiers to train on an M1 Abrams tank. Not only does it cost about $67 per mile to operate, but Sabot ammunition rounds cost about $1,175 each, and HEAT rounds cost about $830 each.[/quote]
MathJax will be triggered for this substring: $67 per mile to operate, but Sabot ammunition rounds cost about $
This is unexpected and confusing, paticularly because it is difficult to prevent. I would expect that the inline mathjax would enforce a word boundary before and after the inline section. Or expressed Via Regex: /\b$[^$]+$\b/
The dollar-sing delimiters are not enabled in MathJax by default for just this reason. If dollar signs are being processed, that would have to be due to your configuration adding them as inline math delimiters. Your page no longer loads MathJax, so I can't check the configuration, but one way to avoid the problem is to not enable dollar signs as delimiters. If you enable dollar-sign delimiters it is customary also to enable processEscapes so that you can use \$ to prevent the dollar from being treated as a delimiter.
Note that your suggested regular expression will not help, since /\b$/ is true for any dollar sign (the dollar sign is itself a word break).
at would have to be due to your configuration adding them as inline math delimiters.
As pointed out on the other bug, and in my comment from 10 days ago, it's not at all clear where such configuration options are actually... configured, for Discourse.
When fed the raw text:
MathJax will be triggered for this substring:
$67 per mile to operate, but Sabot ammunition rounds cost about $
This is unexpected and confusing, paticularly because it is difficult to prevent. I would expect that the inline mathjax would enforce a word boundary before and after the inline section. Or expressed Via Regex:
/\b$[^$]+$\b/
Examples:
https://what.thedailywtf.com/t/lighting-logic/2754/9?u=accalia
https://what.thedailywtf.com/t/mathjax-playground/50449/10?u=accalia
The text was updated successfully, but these errors were encountered: