Configuration
A template's configuration describes both what the template expects to render and how the output structure and naming should be. Every template must start with a configuration block.
Overview
The configuration starts off as a basic HTML comment tag...
<!-- -->
... with the word readstor
...
<!-- readstor -->
...and a new line.
<!-- readstor
-->
The YAML configuration is then placed inside the tag. For example:
<!-- readstor
group: my-vault
context: book
structure: nested
extension: md
names:
book: "{{ book.author }} - {{ book.title }}"
annotation: "{{ annotation.slugs.metadata.created }}-{{ book.slugs.title }}"
directory: "{{ book.author }} - {{ book.title }}"
-->
...
Note that the final rendered output file will not include its template's configuration. Additionally, if the configuration ended with trailing line-breaks, a single one of them is removed. This allows for some extra whitespace while working with a template without affecting final rendered output.
A quick rundown of each configuration key:
Key | Description |
---|---|
group | The Template Group name. |
context | The Context Mode or what the template will render. |
structure | The Structure Mode or how the output files will be structured. |
extension | The template's output File Extension. |
names | The template Names for generating file and directory names. |