d2l-ai / d2l-book

Books with Jupyter notebooks
https://book.d2l.ai/
Apache License 2.0
230 stars 99 forks source link

New feaure request: Adding theorem/proof blocks. #33

Open RootofalleviI opened 3 years ago

RootofalleviI commented 3 years ago

Hey D2L team,

Thanks for providing us with this great tool!

One small question or feature request: Is it possible to support the functionalities for theorems/proof blocks, e.g., something like this: https://sphinx-proof.readthedocs.io/en/latest/syntax.html? Maybe this requires defining new syntax in Markdown (e.g., custom tokens for start/end of environments) and translate that into rst.

Thanks!

RootofalleviI commented 3 years ago

I tried to add this line to config.ini: sphinx_extensions = myst_parser sphinx_proof which gives me an error: Extension error: source_suffix '.md' is already registered which I believe is caused by the extension clash between recommonmark and myst_parser.

Since recommonmark is now deprecated (https://github.com/readthedocs/recommonmark), could we replace it by myst?

Thanks!

`