View source: R/pandoc-template.R
pandoc_export_highlight_theme | R Documentation |
Pandoc highlighting can be customize using a JSON .theme
file, passed to
--highlight-style=
flag. This function
allows to generate the JSON version of one of the supported highlighting
style.
pandoc_export_highlight_theme(
style = "pygments",
output = style,
version = "default"
)
style |
One of the support highlighting style. (See |
output |
Path (without extension) where to export the JSON |
version |
Version to use. Default will be the
|
The .theme
extension is required and it will be enforced in during the
export by this function.
the filename where the theme has been exported.
This correspond to the --print-highlight-style
CLI flag using
also --output
to write a export a data file built in Pandoc.
# export tango theme used by Pandoc highlighting to `tango.theme` file
pandoc_export_highlight_theme("tango")
pandoc_export_highlight_theme("pygments", output = "my_theme.theme")
pandoc_export_highlight_theme("zenburn", version = "system")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.