mystmd
mystmd copied to clipboard
Add a feature for including content only in specific export types
Building multiple export types from the same source would be improved if there was an option to include some content in only one export type. For example, if I want a video for a web build and an image for a pdf build, I could do something like:
:::{only:web}

:::
:::{only:pdf}

:::
One example of where this could be used is https://github.com/jupyter-book/mystmd/pull/1744
Regarding implementation, this could be a directive, like my example above, or it could be an option on existing directives. It could also come in as a class, following this proposal: https://github.com/jupyter-book/myst-enhancement-proposals/pull/28