Include
Th' include
shortcode includes other planks, resources or files from yer project.
Usage
While th' examples be us'n shorrrtcodes wit' named parameter ye be free t' use positional as well or also call this shortcode from yer own partials.
{{% include file="shortcodes/include/INCLUDE_ME.md" %}}
{{% include "shortcodes/include/INCLUDE_ME.md" %}}
{{ partial "shortcodes/include .html" (dict
"page" .
"file" "shortcodes/include/INCLUDE_ME.md"
)}}
Th' included files can even contain Marrrkdown an' will be taken into account when generat'n th' t'ble o' contents.
Parameter
Name | Posit'n | Default | Notes |
---|---|---|---|
file | 1 | <empty> | Th' path t' th' plank, resource or file t' be included. Plank an' resource paths adhere t' Hugo’s logical path. If not found by logical path it falls back t' Hugo’s build-in readFile funct'n |
hidefirsthead'n | 2 | false |
When true an' th' included file contains head'ns, th' first head'n will be hidden. This comes 'n handy, eg. if ye include otherwise standalone Marrrkdown files. |
Examples
Arbitrary Rrrambl'n
{{% include "shortcodes/include/INCLUDE_ME.md" %}}
Ye can add standard markdown rules:
...and even source code
th' possibilities be endless (almost - includ'n other shorrrtcodes may or may not work) (almost - includ'n other shorrrtcodes may or may not work)
-
Et Cetera (English: /ɛtˈsɛtərə/), abbreviated t' etc., etc, et cet., be a Latin expression that be used 'n English t' mean “and other similar things”, or “and so forth” ↩︎