This post is addressed to who:
* wants to insert SVG images in its DokuWiki'files;
* already uses MathJax (plugin MathJax is required);
* doesn't have high standards.
I was looking at a way to "draw" (write) some SVG, in like manner of TikZ for who uses LaTex, and I found this project, called, XyJax, which is "an almost Xy-pic compatible extension for MathJax."
It's important to note that this is a work in progress project but you can see here (
http://sonoisa.github.io/xyjax/xyjax.html) what is already done!
If you want to run some test you have to load the XyJax extension with the code:
MathJax.Ajax.config.path["Contrib"] = "//cdn.mathjax.org/mathjax/contrib";
MathJax.Hub.Config({
tex2jax: {
inlineMath: [ ["$","$"], ["\\(","\\)"] ],
displayMath: [ ["$$","$$"], ["\\[","\\]"] ],
processEscapes: true
},
TeX: {
equationNumbers: {autoNumber: "AMS"},
extensions: ["[Contrib]/xyjax/xypic.js"]
}
});
You have to specify the path (first line) and then load the extension in the square brackets (comma separated values if you have other extensions).
Then, in your page:
$$
\begin{xy}
...
\end{xy}
$$
This is the link to the Xy-pic' manual:
http://texdoc.net/texmf-dist/doc/generic/xypic/xyrefer.pdf
Honestly, I've never used Xy-pic, but, in order to test what XyJax can does, I write down some usefull notes. Maybe they will be save time to someone...