klyn.code.klyn.KlynDocComment.exampleText
method
public static exampleText(text as String) as String
Description

Returns the example section of a KlynDoc comment (either explicit @example or trailing fenced code block after @ tags).

Parameters
ParameterDescription
textCleaned documentation text.
Returns

Example markdown/code text, or "".

Example
import klyn.code.klyn

doc = "@example `compute(1)`"
assert KlynDocComment.exampleText(doc) == "`compute(1)`"