Module Server.Doc

module Doc: sig .. end


Server Documentation
type chapter = [ `Kernel | `Plugin of string | `Protocol ] 
The main chapters of the documentation.
type page 
A page of the server documentation.
val path : page -> string
val href : page -> string -> Markdown.href
val chapter : page -> chapter
val page : chapter -> title:string -> filename:string -> page
Obtain the given page in the server documentation.

The page initially contains an introductory section read from the share directory:


val publish : page:page ->
?name:string ->
?index:string list ->
title:string ->
?contents:Markdown.elements ->
?generated:(unit -> Markdown.elements) -> unit -> Markdown.href
Adds a section in the corresponding page. Returns an href to the published section. If index items are provided, they are added to the server documentation index.
val dump : root:string -> ?meta:bool -> unit -> unit
Dumps all published pages of documentations. Unless ~meta:false, also generates METADATA for each page in <filename>.json for each page.