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
one of our teachers reported that the auto-detection of MATLAB code fails. Especially, the example MATLAB code from https://highlightjs.org/static/demo/ is recognized as Makefile:
Upstream in highlight.js, there is just one issue covering this issue on highlightjs/highlight.js#819 - but it deals with file extensions and in Moodle the rendered code does not have any file extensions.
I am aware that you are saying on https://moodle.org/plugins/filter_syntaxhighlighter that there isn't any mechanism to force the language to be used, but the MATLAB issue brings me to a point where I think that this could indeed be useful or even needed.
Do you have an opinion or solution proposal for this catch-22?
Cheers,
Alex
The text was updated successfully, but these errors were encountered:
Finally looking at this. I have a pull request to be able to specify a language #11 . I think this will go part the way to fixing your issue.
And I noticed that the js I include doesn't contain the language matlab, so I'll look to make sure that's included. I might include a bunch of other languages.
Updated to latest version, and included matlab. Autodetection should work, however, you can also now specify the language using ```lang:matlab;; my matlab code ``` notation
Hi Mark,
one of our teachers reported that the auto-detection of MATLAB code fails. Especially, the example MATLAB code from https://highlightjs.org/static/demo/ is recognized as Makefile:
Upstream in highlight.js, there is just one issue covering this issue on highlightjs/highlight.js#819 - but it deals with file extensions and in Moodle the rendered code does not have any file extensions.
I am aware that you are saying on https://moodle.org/plugins/filter_syntaxhighlighter that there isn't any mechanism to force the language to be used, but the MATLAB issue brings me to a point where I think that this could indeed be useful or even needed.
Do you have an opinion or solution proposal for this catch-22?
Cheers,
Alex
The text was updated successfully, but these errors were encountered: