🍄FeatureTransclusion

Transclusion is the mechanism of including contents of other hyphae into one hypha.

To include a hypha named yoghurt, write a line like that:

<= yoghurt

In release/1.2, the transclusion semantics were changed. If you were using transclusion before that release, please update your hyphae. For time being, the engine will report transclusion using the old syntax with colon.

Transclusion lines start with a reverse-rocket symbol (<=) followed by zero or more spaces. The text on the line before a line break or a pipe character (|) is called target or target hypha. If there is a pipe, the text after it is called selector. If there is no pipe, the selector is empty. Both target and selector are stripped of left-side and right-side whitespace before further processing.

<= target hypha
<= target hypha |
<= target hypha | selector

Selector

The selector specifies what part of the target to transclude. The parser checks for these words:

  • full. Transclude the whole document.

  • text. Transclude all text.

  • attachment. Transclude attachment only.

  • description. Transclude first paragraph only.

  • overview. Short for both attachment and description.

If only one of them is found, the corresponding part is transcluded. If several are found, the bigger transclusion is done. If none are found, overview is implicitly considered.

Additionally, if the word blend is present, the transclusion is rendered without the gray box and the link to the target by default. Wiki administrators can override this behaviour.

This is an actual transclusion of a hypha below.

u/bouncepaw/userpic

This image is based on a drawing from Kunstformen der Natur by Ernst Haeckel.

Recursive transclusion is also supported but it is limited to three iterations.