package omd

  1. Overview
  2. Docs
type t = element list
and ref_container = < add_ref : string -> string -> string -> unit ; get_all : (string * (string * string)) list ; get_ref : string -> (string * string) option >
and element = Omd_representation.element =
  1. | H1 of t
  2. | H2 of t
  3. | H3 of t
  4. | H4 of t
  5. | H5 of t
  6. | H6 of t
  7. | Paragraph of t
  8. | Text of string
  9. | Emph of t
  10. | Bold of t
  11. | Ul of t list
  12. | Ol of t list
  13. | Ulp of t list
  14. | Olp of t list
  15. | Code of name * string
  16. | Code_block of name * string
  17. | Br
  18. | Hr
  19. | NL
  20. | Url of href * t * title
  21. | Ref of ref_container * name * string * fallback
  22. | Img_ref of ref_container * name * alt * fallback
  23. | Html of string
  24. | Html_block of string
  25. | Html_comment of string
  26. | Blockquote of t
  27. | Img of alt * src * title
  28. | X of < name : string ; to_html : ?indent:int -> (t -> string) -> t -> string option ; to_sexpr : (t -> string) -> t -> string option ; to_t : t -> t option >
and fallback = string
and name = string
and alt = string
and src = string
and href = string
and title = string
type code_stylist = lang:string -> string -> string
val of_string : ?extensions:Omd_representation.extensions -> ?default_lang:name -> string -> t
val set_default_lang : name -> t -> t
val to_html : ?pindent:bool -> ?nl2br:bool -> ?cs:code_stylist -> t -> string
val to_markdown : t -> string
val to_text : t -> string
val toc : ?start:int list -> ?depth:int -> t -> t
OCaml

Innovation. Community. Security.