An include is an optional asset that can be inserted into fragment and template assets.
- file location: root/source/includes
- file type/content: .html/HTML or .md/Markdown
- front matter required: no
- required predefined front matter properties: none
- optional predefined front matter properties: appendToTarget
- applicable data-trio-* attributes: data-trio-callback, data-trio-link
Inclusion By File Name
To insert an include asset by its file name, you decorate the tag that you are targeting as the insertion point with a data-trio-include attribute, and assign it the name of the include file, including its file.extension (i.e. .html or .md).
Inclusion By Indirect Value
Inclusion by indirect value allows fragments to name the include files whose content is to be inserted into their associated templates.
To insert an include asset by indirect value, you decorate the tag in the template that you are targeting as the insertion point with a data-trio-include attribute, and assign it the name of a front matter property that is declared in the template's associated fragment whose value is the name of the include file.
Your Financial Support Of This Project Is Greatly Appreciated
Trio is an open source project and is therefore free of charge to use both for noncommercial and commercial use, but when you use Trio to create a new website, please consider donating a few bucks. It doesn't take very long, the process is secure, and it will allow us to continue to support the community and to maintain and enhance Trio going forward.
Show your ❤️, add your ★ to the Github repo.