michael-brade / LaTeX.js

JavaScript LaTeX to HTML5 translator
https://latex.js.org
MIT License
736 stars 58 forks source link

amsmath #130

Open superGold opened 3 years ago

superGold commented 3 years ago

Great project, but amsmath package currently not supported. Are there any plans to include this please? How does one add to the packages in general?

michael-brade commented 3 years ago

Thanks! I guess this one would be as easy as adding a package/amsmath.ls with an empty AmsMath class or so. AMS is supported by KaTeX, which is part of LaTeX.js. Maybe some math-environments that can be used directly in text mode have to be added to forward their contents to KaTeX...

superGold commented 3 years ago

Thanks for the hint - I did get katex working, which does support the matrix representations I'm looking for. However, I still feel latex.js is better for what I'm trying to do, which I should explain properly. I would like to serve a static webpage which renders the latex with my doc typesetting and the equations etc etc. I do run linux servers, but I don't want each visitor to be querying my server for rendering a doc. I'd rather have my static webpages serve the doc completely, which would save my server from being queried each time a student views my notes. At the moment, I load latex.js through a public CDN; out of the box, it does support some packages, but not asmmath [which I need due to the matrix equations] If there's no plan to support asmmath in latex.js natively, i'd really appreciate some hints on integrating this package into a new instance of latex.js which i can serve through my own CDN

superGold commented 3 years ago

Solved! - following your earlier comment, I just added kaTex to my page and omitted the attempt to \usepackage amsmath. Works fine; all the amsmath support seems to be absorbed in latex.js. Thanks again

pmarcelino commented 1 year ago

@superGold I'm having the same issue you had. Can you detail your solution?

mojtabakarimi commented 1 year ago

Solved! - following your earlier comment, I just added kaTex to my page and omitted the attempt to \usepackage amsmath. Works fine; all the amsmath support seems to be absorbed in latex.js. Thanks again

I'm having the same issue you had. Can you detail your solution?