Directly? I don't know. If I needed to do that myself, for few enough images that I could do it manually, I would run pdflatex to get a pdf file and then pick out the image parts and convert to svg using Adobe Illustrator (probably any other vector graphics program that can read pdf and write svg would work equally well).
+Péter Erben there isn't one that runs in the browser (that I know of), but I've been working my way up to making such a thing. There's a stackexchange thread which gives a few options for converting PDF to SVG: http://tex.stackexchange.com/questions/51757/how-can-i-use-tikz-to-make-standalone-svg-graphics In short: use the standalone documentclass to create a PDF containing only your figure, then pdf2svg to make an SVG file. There was a project called LaTeX2HTML5 which implemented a teeny tiny subset of pstricks and alowed you to make interactive diagrams: https://github.com/pyramation/LaTeX2HTML5
"Why are Wikipedia's mathematics formulas still formatted so badly?"
Because some big browser developers like Microsoft and Google do not support it despite this has been a goal for HTML5. In the old days when Microsoft did not support W3C constructs one said: Shame on them, and use Mozilla Firefox. And it worked. Even the Internet Explorer learned SVG after being criticised by Tim Berners-Lee.
But now everybody’s darling is Google's Chrome and things changed: For Google, the new leader (in usage share) great understanding is shown that it is not worthwhile to invest in these 'small potatoes' (as you said).
"Systems such as MathJax and KaTeX have already shown that HTML alone is perfectly capable of describing the visual presentation of mathematical formulas."
But this is wrong. it is not HTML alnone, it is Javascript. And 3rd party Javascript at that (unless the author hosts MathJax themselves, which I expect nobody does). Have we reached the point where HTML and JS are considered one thing? Gimme a break.
And (as a consequence) this is also wrong:
"Their slogan is 'it just works', and it's true."
Not if you use RequestPolicy or similar - then you get a mess (probably just the raw LaTeX) until you click the red flag to approve the redirect. True, you only need to do that once so this is a minor point - until, that is, the MathJax site itself starts redirecting to random CDNs with unpredictable domain names ... the wonderful world of Web 2.0.
Answering rant with a rant :-) But please be sure I love reading your stuff.
+Ian Zimmerman it is a piece of software that converts LaTeX into HTML (or really the equivalent DOM objects, but it might as well be HTML), thereby showing that HTML works. It happens to be written in JavaScript, allowing it to run browser-side. But I think you should think of the product of the conversion and the software that does the conversion as being separate things.
It imposes additional work on other developers -- work which would have been factored out by MathML. An example I run into this week: jupyter notebooks, latest version. My notebook is long and has many TeX cells. Neither saving as a html piece nor the print preview works. It does work well for small notebooks with little TeX. But for large ones there is a timing problem: MathJax might take really long and the consumer (jupyter) has difficulties to get the synchronization right in these cases. OK, not MathJax's problem, but there would be no problem with MathML instead of MathJax I am sure.
There's a stackexchange thread which gives a few options for converting PDF to SVG: http://tex.stackexchange.com/questions/51757/how-can-i-use-tikz-to-make-standalone-svg-graphics
In short: use the standalone documentclass to create a PDF containing only your figure, then pdf2svg to make an SVG file.
There was a project called LaTeX2HTML5 which implemented a teeny tiny subset of pstricks and alowed you to make interactive diagrams: https://github.com/pyramation/LaTeX2HTML5
Because some big browser developers like Microsoft and Google do not support it despite this has been a goal for HTML5. In the old days when Microsoft did not support W3C constructs one said: Shame on them, and use Mozilla Firefox. And it worked. Even the Internet Explorer learned SVG after being criticised by Tim Berners-Lee.
But now everybody’s darling is Google's Chrome and things changed: For Google, the new leader (in usage share) great understanding is shown that it is not worthwhile to invest in these 'small potatoes' (as you said).
'Blame Google' instead of 'Blame MathML'?
But this is wrong. it is not HTML alnone, it is Javascript. And 3rd party Javascript at that (unless the author hosts MathJax themselves, which I expect nobody does). Have we reached the point where HTML and JS are considered one thing? Gimme a break.
And (as a consequence) this is also wrong:
"Their slogan is 'it just works', and it's true."
Not if you use RequestPolicy or similar - then you get a mess (probably just the raw LaTeX) until you click the red flag to approve the redirect. True, you only need to do that once so this is a minor point - until, that is, the MathJax site itself starts redirecting to random CDNs with unpredictable domain names ... the wonderful world of Web 2.0.
Answering rant with a rant :-) But please be sure I love reading your stuff.
It imposes additional work on other developers -- work which would have been factored out by MathML. An example I run into this week: jupyter notebooks, latest version. My notebook is long and has many TeX cells. Neither saving as a html piece nor the print preview works. It does work well for small notebooks with little TeX. But for large ones there is a timing problem: MathJax might take really long and the consumer (jupyter) has difficulties to get the synchronization right in these
cases. OK, not MathJax's problem, but there would be no problem with MathML instead of MathJax I am sure.