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
Per say it's not really an issue but some linter/parser (more specifically the Firefox Add-ons linter: https://github.com/mozilla/addons-linter) will parse these "JavaScript" files and fail:
Code Message Description File Line Column
JS_SYNTAX_ERROR JavaScript syntax error There is a JavaScript syntax error in your code; validation cannot continue on this file. vendor/MathJax-3.0.5/sre/mathmaps/nemeth.js 2 30
JS_SYNTAX_ERROR JavaScript syntax error There is a JavaScript syntax error in your code; validation cannot continue on this file. vendor/MathJax-3.0.5/sre/mathmaps/fr.js 2 26
JS_SYNTAX_ERROR JavaScript syntax error There is a JavaScript syntax error in your code; validation cannot continue on this file. vendor/MathJax-3.0.5/sre/mathmaps/es.js 2 26
JS_SYNTAX_ERROR JavaScript syntax error There is a JavaScript syntax error in your code; validation cannot continue on this file. vendor/MathJax-3.0.5/sre/mathmaps/en.js 2 26
In other words, if you are embedding MathJax 3.0.5 in a Firefox Add-on, you cannot publish your extension anymore.
The linter was not complaining with MathJax 3.0.1 because the structure and the files content changed.
In MathJax 3.0.1, each files contain a single Array on a single line:
Is your feature request related to a problem? Please describe.
Currently, the files in the
mathmaps
directory are using the.js
extension but they are really.json
files. For instance:sre/mathmaps/es.js
Per say it's not really an issue but some linter/parser (more specifically the Firefox Add-ons linter: https://github.com/mozilla/addons-linter) will parse these "JavaScript" files and fail:
In other words, if you are embedding MathJax 3.0.5 in a Firefox Add-on, you cannot publish your extension anymore.
The linter was not complaining with MathJax 3.0.1 because the structure and the files content changed.
In MathJax 3.0.1, each files contain a single Array on a single line:
sre/mathmaps/es/functions/algebra.js
Describe the solution you'd like
I think the files should use the
.json
file extension instead of.js
.Describe alternatives you've considered
I guess we could also keep the
.js
file extension but declare a variable so linter and JS parser won't fail:sre/mathmaps/es.js
Original issue: mathjax/MathJax#2403
The text was updated successfully, but these errors were encountered: