It seems Javascript magic is not recognized.
Example:
%%javascript
console.log("hello world")
==> Error, Unknown magic "javascript".
My aim in using Javascript magic is to run the following code
to enable numbering of LaTeX equations:
%%javascript
MathJax.Hub.Config({ TeX: { equationNumbers: { autoNumber: "AMS" } } });