Public API
DocumenterVitepress.DocumenterVitepress Module
DocumenterVitepressSimilar to DocumentationMarkdown.jl but designed to work with vitepress.
sourceDocumenterVitepress.MarkdownVitepress Type
MarkdownVitepress(; repo, devbranch, devurl, kwargs...)This is the main entry point for the Vitepress Markdown writer.
It is a config which can be passed to the format keyword argument in Documenter.makedocs, and causes it to emit a Vitepress site.
Quick start
When invoking Documenter.makedocs, replace the default format=Documenter.HTML(...) with:
format=DocumenterVitepress.MarkdownVitepress(; repo = "...", devbranch = "...", devurl = "...")Keyword arguments (config)
repo: Required: The full URL of the repository to which the documentation will be deployed.devbranch: The name of the development branch, likemasterormain.devurl: The URL path to the development site, likedevordev-branch.deploy_url: The URL of the repository to which the documentation will be deployed. This must be the full URL, includinghttps://, likehttps://rafaqz.github.io/Rasters.jlorhttps://geo.makie.jl/.description: A description of the website as a String.build_vitepress: Determines whether to build the Vitepress site or only emit markdown files. Defaults totrue, i.e., building the full Vitepress site.install_npm: Determines whether to runnpm installbefore building the Vitepress site. Defaults totrue.md_output_path: The path to which the Markdown files will be output. Defaults to$build/.documenter.clean_md_output: Determines whether to clean up the Markdown assets after build, i.e., whether to remove the contents ofmd_output_pathafter the Vitepress site is built. Options are:nothing: Default. Only remove the contents ofmd_output_pathif the documentation will deploy, to save space.true: Removes the contents ofmd_output_pathafter the Vitepress site is built.false: Does not remove the contents ofmd_output_pathafter the Vitepress site is built.
deploy_decision: DeployDecision from Documenter.jl. This is used to determine whether to deploy the documentation or not. Options are:nothing: Default. Automatically determine whether to deploy the documentation.Documenter.DeployDecision: Override the automatic decision and deploy based on the passed config.
It might be useful to use the latter if DocumenterVitepress fails to deploy automatically. You can pass a manually constructed
Documenter.DeployDecisionstruct, or the output ofDocumenter.deploy_folder(Documenter.auto_detect_deploy_system(); repo, devbranch, devurl, push_preview).assets: A list of assets, the same as what is provided to Documenter's HTMLWriter.
Extended help
The repo kwarg is used to set the edit link for the documentation.
The devbranch and devurl kwargs are used to set the path of the static site, which Vitepress expects in advance.