What I’m trying to do
I would like Mathematica code blocks to format nicely like they do for other languages with syntax coloring.
Consider in the following two code blocks:
def fun():
x = 1
f[x0_] := Module[{x = x0},
While[x > 0, x = Log[x]]; x
]
The python code looks good, but the wolfram code looks like verbatim:
What I’ve tried
Mathematica (aka wolfram language) is less popular but is still supported in many editors like Sublime e.g. WolframLanguage - Packages - Package Control)
I managed to find a project that formats wolfram code with css/html here: GitHub - halirutan/Mathematica-Source-Highlighting: Highlighting of Mathematica code for Mathematica.stackexchange
I’ve tried to hook it up, but I don’t know how to do this properly, any guidance here would be much appreciated!