module Tags:sig
..end
type
highlight = {
|
lang : |
(* |
optional language of syntax
| *) |
|
body : |
(* |
code to be highlighted
| *) |
|
linenos : |
(* |
whether line numbers should be emitted
| *) |
highlight
represents the various syntax highlighting options.val mk_highlight : ?lang:string ->
?body:Astring.String.sub ->
?linenos:bool -> unit -> highlight
mk_highlight
constructs a Jekyll_liquid.Tags.highlight
value. lang
defaults to
None
, body
defaults to Astring.String.Sub.empty
and linenos
defaults to false
.val pp_highlight : highlight Fmt.t
val highlight : string -> highlight option
highlight s
attempts to parse the contents of a {% highlight %}
tag.
s
should have had the tags removed via extract_tag
and just contain
the tag body.val endhighlight : string -> bool
endhighlight s
checks if a {% endhighlight %}
tag is present.
s
should have had the tags removed via extract_tag
and just contain
the tag body.