hugoDocs/content/variables/shortcodes.md
2017-03-12 20:21:01 -05:00

1.1 KiB

title linktitle description date publishdate lastmod categories tags draft weight aliases toc
Shortcode Variables Shortcode Variables Shortcodes can access page variables and also have their own specific built-in variables. 2017-03-12 2017-03-12 2017-03-12
variables and params
shortcodes
false 20
false

Shortcodes have access to parameters delimited in the shortcode declaration via .Get, page- and site-level variables, and also the following shortcode-specific fields:

.Parent
provides access to the parent shortcode context in nested shortcodes. This can be very useful for inheritance of common shortcode parameters from the root.
.IsNamedParams
boolean that returns true when the shortcode in question uses named rather than positional parameters
.Inner
represents the content between the opening and closing shortcode tags when a closing shortcode is used