What is a shortcode?
Believe it or not, you’ve already been using shortcodes in this book. The template tags we’ve used to do things such as loops and conditionals are shortcodes. In their template engines, they’re usually referred to as “tags.” In the case of 11ty, the custom shortcode functionality is used as a wrapper and set of conveniences around each template engine’s custom tag functionality.
This allows 11ty developers to develop tags for individual languages or all the template languages and use the same syntax.
Not all template engines support custom shortcodes. According to the 11ty documentation, the engines that support shortcodes are Liquid, Nunjucks, Handlebars, and JavaScript templates. While the basic functionality is universal, each template engine has its own unique features, as well.
Keyword arguments
One example of differences is the use of keyword arguments inside of Nunjucks. 11ty’s Nunjucks implementation...