MyST-Parser
MyST-Parser copied to clipboard
`parsed-literal` does not preserve code-highlighting
I am not sure if this is a bug or documentation issue. Basically I saw CMake's documentation that uses parsed-literal
, and I wanted to port that design to my myst documentation. But I cannot get the code-highlighting to detect the language correctly. I don't know if there is a specific that should be enabled for that or is this specific to RST?
But I cannot get the code-highlighting to detect the language correctly
Heya, I'm a bit confused what you mean by this? parsed-literal
will parse the containing block as MyST, it is not for code highlighting: https://docutils.sourceforge.io/docs/ref/rst/directives.html#parsed-literal-block
From what I've read on forums it is only supposed to parse its known markups like the links. For myst, it does do that, but steadily then the code highlighting is lost.
Alternatively would it be possible to code something to markup only markdown links (reference style links or autolinks might be tricky) and pass everything else to either code-highlight parser?