Debian Codegraph @

docs/layouts/_shortcodes/include.html

raw
1 {{/*
2 Renders the page using the RenderShortcode method on the Page object.
3
4 You must call this shortcode using the {{% %}} notation.
5
6 @param {string} (positional parameter 0) The path to the page, relative to the content directory.
7
8 @example {{% include "functions/_common/glob-patterns" %}}
9 */}}
10
11 {{- with .Get 0 }}
12 {{- with or ($.Page.GetPage .) (site.GetPage .) }}
13 {{- .RenderShortcodes }}
14 {{- else }}
15 {{- errorf "The %q shortcode was unable to find %q. See %s" $.Name . $.Position }}
16 {{- end }}
17 {{- else }}
18 {{- errorf "The %q shortcode requires a positional parameter indicating the path of the file to include. See %s" .Name .Position }}
19 {{- end }}