Hi, first off, many thanks for this extension; it's an absolute life-saver when dealing with any sort of Markdown!
Is it possible to apply separate styling to the printed HTML instead of the Markdown preview?
When printing the current document to HTML, I was looking to apply an external stylesheet. I found I could do this by adding the following snippet to VS Code's settings.json.
"markdown.styles": [
"https://codepen.io/rdhar/pen/3356f9bb481aba5cc308018ab1f80554.css"
],
However, this also applies the styling within VS Code's Markdown preview as well… which isn't a great look. As such, it'd be ideal only apply styling to the printed HTML and leave the Markdown preview as-is.
Thank you for your time.
Thanks for the suggestion.
It makes sense to have different styles for preview and print (for example, many people use dark theme but I guess few would like the exported HTML to be dark).
Technically, it is very easy (see the code). I just realized we already have an "oppsite" option includesVscodeStyles. I need to think of a better solution and probably need more feedback from other users.
It makes sense to have different styles for preview and print (for example, many people use dark theme but I guess few would like the exported HTML to be dark).
That's precisely my exact use-case for this!
Technically, it is very easy (see the code). I just realized we already have an "oppsite" option includesVscodeStyles. I need to think of a better solution and probably need more feedback from other users.
I didn't even realize it could be such a simple flag-like substitution.
I should mention, I already make use of "markdown.extension.print.includeVscodeStylesheets": false, to get rid of the standard styles from conflicting with what's set in "markdown.styles": […].
Would love to see this implemented, perhaps, something like "markdown.extension.preview.includeStylesheets": false, to leave the preview untouched. Definitely agreed that more user feedback/input would help better shape this suggested request.
Thanks for your response, really appreciate it!
Most helpful comment
That's precisely my exact use-case for this!
I didn't even realize it could be such a simple flag-like substitution.
I should mention, I already make use of
"markdown.extension.print.includeVscodeStylesheets": false,to get rid of the standard styles from conflicting with what's set in"markdown.styles": […].Would love to see this implemented, perhaps, something like
"markdown.extension.preview.includeStylesheets": false,to leave the preview untouched. Definitely agreed that more user feedback/input would help better shape this suggested request.Thanks for your response, really appreciate it!