<@ macro typeList(types) -@> <@ set separator = joiner("|") @> <@ for type in types @><$ separator() $><$ type | code $><@ endfor @> <@- endmacro -@> <@ macro paramTable(params, isDirective) @>

<@ if isDirective @>Attr<@ else @>Param<@ endif @> | Type | Details
--- | --- | ---
<@ for param in params @>
<$ param.name $> <@ if param.alias @>| <$ param.alias $><@ endif @> <@ if param.type.optional @> (optional) <@ endif @> | <$ typeList(param.typeList) $> | <$ param.description | marked $> <@ if param.default @> (default: <$ param.default $>) <@ endif @>
<@ endfor @>

<@ endmacro @> <@- macro directiveParam(name, type, join, sep) @> <@- if type.optional @>[<@ endif -@> <$ name | dashCase $><$ join $><$ type.description $><$ sep $> <@- if type.optional @>]<@ endif -@> <@ endmacro -@> <@- macro functionSyntax(fn) @> <@- set sep = joiner(', ') -@> `<$ fn.name $>(<@- for param in fn.params @><$ sep() $> <@- if param.type.optional @>[<@ endif -@> <$ param.name $> <@- if param.type.optional @>]<@ endif -@> <@ endfor @>)`<@ if fn.alias @>(alias: <$ fn.alias $>)<@ endif @> <@ endmacro -@> <@- macro typeInfo(fn) -@> <$ typeList(fn.typeList) $> <$ fn.description $> <@- endmacro -@>