The vscode-pandoc Visual Studio Code extension lets you quickly render markdown files as a pdf
, word document
or html
file.
You need to install Pandoc - a universal document converter.
Two ways to run the extension. You need to have a markdown file open.
F1
on Windows (shift+cmd+P
on Mac), type pandoc
, press Enter
ctrl+K
then P
(cmd+K
then P
on Mac)Then choose from the list what document type you want to render and press enter
(you can also type in the box rather than cursor around).
Enlarged version of the video.
July 9, 2016
January 17, 2016
January 16, 2016
example:
//-------- Pandoc Option Configuration --------
// pandoc .pdf output option template that you would like to use
"pandoc.pdfOptString": "",
// pandoc .docx output option template that you would like to use
"pandoc.docxOptString": "",
// pandoc .html output option template that you would like to use
"pandoc.htmlOptString": ""
$ pandoc inFile.md -o outFile.{pdf|word|html}
"pandoc.pdfOptString": "--latex-engine=lualatex -V documentclass=ltjarticle -V geometry:a4paper -V geometry:margin=2.5cm -V geometry:nohead",
--latex-engine=lualatex
: need to create a Japanese PDF-V documentclass=ltjarticle
: need to create a Japanese PDF-V geometry:a4paper -V geometry:margin=2.5cm -V geometry:nohead"
: geometory optionsWord(docx)
pandoc.docxOptString": "",
HTML5
"pandoc.htmlOptString": "-s -t html5"
-s
: produce a standalone document-t html5
: HTML5 output formatFor more information please refer to the Pandoc User's Guide.