sagemathinc / cocalc

CoCalc: Collaborative Calculation in the Cloud
https://CoCalc.com
Other
1.17k stars 216 forks source link

add support for some of the myst extensions to cocalc's markdown #5948

Open williamstein opened 2 years ago

williamstein commented 2 years ago

The official myst extension for markdown is only implemented on the backend, relying on Python and Sphinx to generate output. However, there's been a lot of work to port this to something that runs in Javascript using markdown-it plugins, and that's what the

https://executablebooks.github.io/mystjs/

project is doing. For example, this package https://github.com/executablebooks/markdown-it-myst-extras which is part of that project boils down to a 240 line of code typescript file (with no real deps) that implements a handful of well documented markdown-it plugins that are sort of core to the myst spec. I could try to figure out how to support this with cocalc's markdown + slate wysiwyg editing...

williamstein commented 2 years ago

There is a book project I'm trying to support where they are trying to use

https://jupyter-contrib-nbextensions.readthedocs.io/en/latest/nbextensions/latex_envs/README.html

which is a lot more worrisome to me, since it seems dead for 7 years and not as well thought at and popular as myst (to put it mildly).

mforbes commented 2 years ago

@williamstein We will be trying to use Jupyter Book to get a printable version of the analysis course this summer, so I will have much more detailed information about how easy this is, and how to setup a project to produce a high-quality physical book. Happy to reach out when we understand the final conversion better. I am using Introduction to Epidemics as a proof of concept that getting a reasonable print-version out of a set of MyST files is possible.

williamstein commented 2 years ago

Thanks. I'm definitely interesting in supporting what is in https://executablebooks.github.io/mystjs/, and maybe even extending it. I wonder how much of that myst functionality you use?

williamstein commented 2 years ago

Very relevant discussion: https://github.com/jupyterlab/jupyterlab/issues/272

mforbes commented 9 months ago

I opened a discussion on executablebooks

rowanc1 commented 9 months ago

Thanks both for opening an issue over in executable books -- there has been a ton of work put into the MyST renderers and parsers in javascript (mystmd) and jupyterlab-myst and we are very interested in supporting you if we can! Would you be open to a meeting in the next few weeks to talk through any of this? I would like to pull in @stevejpurves who is the core developer on Thebe, which I think could be quite impactful in the work you are describing. I am also working on a lot of markdown editors and wysiwyg authoring tools in my role at Curvenote, and there might be some overlap...! Excited to talk more soon!

My email is rowan@curvenote.com if scheduling something would be better off of github.