Skip to content

Run Templater File

Executes all Templater templates within a single file.

interface RunTemplaterFileButtonAction {
type: 'runTemplaterFile';
templateFile: string; // the path to the template file, relative to the vault root
}

Examples

This will display a banner with the title of the file you are in.

Button
```meta-bind-button
style: primary
label: Say Filename
actions:
- type: runTemplaterFile
templateFile: "templates/Notice.md"
```
File (Notice.md)
<%*
new Notice(tp.file.title);
%>