API
Pandoc.Pandoc — ModulePandocPandoc wrapper to read JSON AST from pandoc
See https://hackage.haskell.org/package/pandoc-types-1.23/docs/Text-Pandoc-Definition.html
Pandoc.Attr — TypeAttr: identifier, classes, key-value pairs
identifier::Stringclasses::Vector{String}attributes::Vector{Tuple{String, String}}
Pandoc.BlockQuote — TypeBlock quote (list of blocks)
content::Vector{Pandoc.Block}
Pandoc.BulletList — TypeBullet list (list of items, each a list of blocks)
content::Vector{Vector{Pandoc.Block}}
Pandoc.Caption — TypeThe caption of a table or figure, with optional short caption.
caption::Pandoc.ShortCaptioncontent::Vector{Pandoc.Block}
Pandoc.Cell — TypeA table cell.
attr::Pandoc.Attralignment::Pandoc.Alignment.Trowspan::Int64colspan::Int64content::Vector{Pandoc.Block}
Pandoc.Citation — TypeCitation
id::Stringprefix::Vector{Pandoc.Inline}suffix::Vector{Pandoc.Inline}mode::Pandoc.CitationMode.Tnote_num::Int64hash::Int64
Pandoc.Cite — TypeCitation (list of inlines)
citations::Vector{Pandoc.Citation}content::Vector{Pandoc.Inline}
Pandoc.Code — TypeInline code (literal)
attr::Pandoc.Attrcontent::String
Pandoc.CodeBlock — TypeCode block (literal) with attributes
attr::Pandoc.Attrcontent::String
Pandoc.ColSpan — TypeThe number of columns occupied by a cell; the width of a cell.
Pandoc.ColSpec — TypeThe specification for a single table column.
alignment::Pandoc.Alignment.Tcolwidth::Pandoc.ColWidth
Pandoc.ColWidth — TypeThe width of a table column, as a percentage of the text width.
width::Union{Float64, Symbol}
Pandoc.Converter — TypeThis is a Converter options struct. It supports all of pandoc's command line arguments.
You can use it like so:
julia> run(Converter(; input = "# Header level 1"))
"<h1 id="header-level-1">Header level 1</h1>
"
julia> c = Pandoc.Converter(; input = "# Header level 1")
`pandoc`
julia> c.from = "markdown";
julia> c.to = "rst";
julia> c
`pandoc -f markdown -t rst`
julia> run(c)
"Header level 1
==============
"mutable struct Converter
input::Union{String, FilePathsBase.AbstractPath, Pandoc.Document, Vector{<:FilePathsBase.AbstractPath}}from::Union{Nothing, String}to::Union{Nothing, String}output::Union{Nothing, String}defaults::Union{Nothing, String}file_scope::Boolsandbox::Booldata_dir::Union{Nothing, String}template::Union{Nothing, String}metadata::Vector{Tuple{String, String}}metadata_file::Union{Nothing, FilePathsBase.AbstractPath}standalone::Boolvariables::Vector{Tuple{String, String}}wrap::Union{Nothing, String}ascii::Booltoc::Booltoc_depth::Union{Nothing, Int64}number_sections::Boolnumber_offset::Union{Int64, Vector{Int64}}top_level_division::Union{Nothing, String}extract_media::Union{Nothing, FilePathsBase.AbstractPath}resource_path::Union{Nothing, FilePathsBase.AbstractPath}include_in_header::Vector{<:FilePathsBase.AbstractPath}include_before_body::Vector{<:FilePathsBase.AbstractPath}include_after_body::Vector{<:FilePathsBase.AbstractPath}no_highlight::Boolhighlight_style::Union{Nothing, String, FilePathsBase.AbstractPath}syntax_definition::Union{Nothing, FilePathsBase.AbstractPath}dpi::Union{Nothing, Int64}eol::Union{Nothing, String}columns::Union{Nothing, Int64}preserve_tabs::Booltab_stop::Union{Nothing, Int64}pdf_engine::Union{Nothing, String}pdf_engine_opt::Union{Nothing, String}reference_doc::Union{Nothing, FilePathsBase.AbstractPath}self_contained::Boolembed_resources::Boolrequest_header::Vector{Tuple{String, String}}no_check_certificate::Boolabbreviations::Union{Nothing, FilePathsBase.AbstractPath}indented_code_classes::Union{Nothing, String}default_image_extension::Union{Nothing, String}filter::Vector{String}lua_filter::Vector{<:FilePathsBase.AbstractPath}shift_heading_level_by::Union{Nothing, Int64}base_header_level::Union{Nothing, Int64}track_changes::Union{Nothing, String}strip_comments::Boolreference_links::Boolreference_location::Union{Nothing, String}markdown_headings::Union{Nothing, String}list_tables::Boollistings::Boolincremental::Boolslide_level::Union{Nothing, Int64}section_divs::Boolhtml_q_tags::Boolemail_obfuscation::Union{Nothing, String}id_prefix::Union{Nothing, String}title_prefix::Union{Nothing, String}css::Union{Nothing, String}epub_subdirectory::Union{Nothing, FilePathsBase.AbstractPath}epub_cover_image::Union{Nothing, FilePathsBase.AbstractPath}epub_title_page::Union{Nothing, Bool}epub_metadata::Union{Nothing, FilePathsBase.AbstractPath}epub_embed_font::Union{Nothing, FilePathsBase.AbstractPath}split_level::Union{Nothing, Int64}chunk_template::Union{Nothing, FilePathsBase.AbstractPath}epub_chapter_level::Union{Nothing, Int64}ipynb_output::Union{Nothing, String}citeproc::Boolbibliography::Union{Nothing, FilePathsBase.AbstractPath}csl::Union{Nothing, FilePathsBase.AbstractPath}citation_abbreviations::Union{Nothing, String}natbib::Boolbiblatex::Boolmathml::Boolwebtex::Union{Nothing, Bool, String}mathjax::Union{Nothing, Bool, String}katex::Union{Nothing, Bool, String}gladtex::Booltrace::Booldump_args::Boolignore_args::Boolverbose::Boolquiet::Boolfail_if_warnings::Boollog::Union{Nothing, String}bash_completion::Boollist_input_formats::Boollist_output_formats::Boollist_extensions::Union{Nothing, Bool, String}list_highlight_languages::Boollist_highlight_styles::Boolprint_default_template::Union{Nothing, FilePathsBase.AbstractPath}print_default_data_file::Union{Nothing, FilePathsBase.AbstractPath}print_highlight_style::Union{Nothing, String, FilePathsBase.AbstractPath}
Pandoc.DefinitionList — TypeDefinition list. Each list item is a pair consisting of a term (a list of inlines) and one or more definitions (each a list of blocks)
content::Vector{Pair{Vector{Pandoc.Inline}, Vector{Vector{Pandoc.Block}}}}
Pandoc.Div — TypeGeneric block container with attributes
attr::Pandoc.Attrcontent::Vector{Pandoc.Block}
Pandoc.Document — TypeDocument
data::Dict{Symbol, Any}pandoc_api_version::VersionNumbermeta::Pandoc.MetaValueblocks::Vector{Pandoc.Block}
Pandoc.Emph — TypeEmphasized text (list of inlines)
content::Vector{Pandoc.Inline}
Pandoc.Figure — TypeFigure
attr::Pandoc.Attrcaption::Pandoc.Captioncontent::Vector{Pandoc.Block}
Pandoc.Header — TypeHeader - level (integer) and text (inlines)
level::Int64attr::Pandoc.Attrcontent::Vector{Pandoc.Inline}
Pandoc.HorizontalRule — TypeHorizontal rule
Pandoc.Image — TypeImage: alt text (list of inlines), target
attr::Pandoc.Attrcontent::Vector{Pandoc.Inline}target::Pandoc.Target
Pandoc.LineBlock — TypeMultiple non-breaking lines
content::Vector{Vector{Pandoc.Inline}}
Pandoc.LineBreak — TypeHard line break
Pandoc.Link — TypeHyperlink: alt text (list of inlines), target
attr::Pandoc.Attrcontent::Vector{Pandoc.Inline}target::Pandoc.Target
Pandoc.ListAttributes — TypeList attributes.
The first element of the triple is the start number of the list.
number::Int64style::Pandoc.ListNumberStyle.Tdelim::Pandoc.ListNumberDelim.T
Pandoc.Math — TypeTeX math (literal)
math_type::Pandoc.MathType.Tcontent::String
Pandoc.Note — TypeFootnote or endnote
content::Vector{Pandoc.Block}
Pandoc.OrderedList — TypeOrdered list (attributes and a list of items, each a list of blocks)
attr::Pandoc.ListAttributescontent::Vector{Vector{Pandoc.Block}}
Pandoc.Para — TypeParagraph
content::Vector{Pandoc.Inline}
Pandoc.Plain — TypePlain text, not a paragraph
content::Vector{Pandoc.Inline}
Pandoc.Quoted — TypeQuoted text (list of inlines)
quote_type::Pandoc.QuoteType.Tcontent::Vector{Pandoc.Inline}
Pandoc.RawBlock — TypeRaw block
format::Stringcontent::String
Pandoc.RawInline — TypeRaw inline
format::Stringcontent::String
Pandoc.Row — TypeRow
attr::Pandoc.Attrcells::Vector{Pandoc.Cell}
Pandoc.RowHeadColumns — TypeThe number of columns taken up by the row head of each row of a 'TableBody'. The row body takes up the remaining columns.
Pandoc.RowSpan — TypeThe number of rows occupied by a cell; the height of a cell.
Pandoc.ShortCaption — TypeA short caption, for use in, for instance, lists of figures.
content::Union{Nothing, Vector{Pandoc.Inline}}
Pandoc.SmallCaps — TypeSmall caps text (list of inlines)
content::Vector{Pandoc.Inline}
Pandoc.SoftBreak — TypeSoft line break
Pandoc.Space — TypeInter-word space
Pandoc.Span — TypeGeneric inline container with attributes
attr::Pandoc.Attrcontent::Vector{Pandoc.Inline}
Pandoc.Str — TypeText (string)
content::String
Pandoc.Strikeout — TypeStrikeout text (list of inlines)
content::Vector{Pandoc.Inline}
Pandoc.Strong — TypeStrongly emphasized text (list of inlines)
content::Vector{Pandoc.Inline}
Pandoc.Subscript — TypeSubscripted text (list of inlines)
content::Vector{Pandoc.Inline}
Pandoc.Superscript — TypeSuperscripted text (list of inlines)
content::Vector{Pandoc.Inline}
Pandoc.Table — TypeTable, with attributes, caption, optional short caption, column alignments and widths (required), table head, table bodies, and table foot
attr::Pandoc.Attrcaption::Pandoc.Captioncolspec::Vector{Pandoc.ColSpec}head::Pandoc.TableHeadbodies::Vector{Pandoc.TableBody}foot::Pandoc.TableFoot
Pandoc.TableBody — TypeA body of a table, with an intermediate head, intermediate body, and the specified number of row header columns in the intermediate body.
attr::Pandoc.Attrrowheadcolumns::Int64head::Vector{Pandoc.Row}content::Vector{Pandoc.Row}
Pandoc.TableFoot — TypeThe foot of a table.
attr::Pandoc.Attrcontent::Vector{Pandoc.Row}
Pandoc.TableHead — TypeThe head of a table.
attr::Pandoc.Attrrows::Vector{Pandoc.Row}
Pandoc.Target — TypeLink target (URL, title).
url::Stringtitle::String
Pandoc.Underline — TypeUnderlined text (list of inlines)
content::Vector{Pandoc.Inline}
Base.run — Methodrun(c::Pandoc.Converter) -> String
Execute command generated by Converter.
Example
julia> run(Pandoc.Converter(input = "# header level 1", from="markdown", to="html"))
"<h1 id="header-level-1">header level 1</h1>
"Pandoc.metadata — Methodmetadata(data::Union{String, AbstractPath})julia> Pandoc.metadata(p"my-unicode-cheat-sheet/index.qmd")
Dict{Symbol, Any} with 7 entries:
:categories => ["neovim", "python", "julia", "rust"]
:keywords => "python, julia, vim, rust, unicode"
:title => "My Unicode cheat sheet"
:summary => "References for various things associated with unicode in Vim, P…
:date => "2020-09-19T02:29:49-06:00"