Add the file and frontmatter modules to the tfile prototype? #1489
DanielJMaxwell
started this conversation in
Ideas & Feature Requests
Replies: 1 comment
-
I don't want to add anything to the TFile prototype since that comes straight from Obsidian. I suppose we could add our own abstraction layer, but I frankly don't have time to do something like that, especially given some of the complexities of updating frontmatter when functions such as It is preferred to use Obsidian APIs for interacting with frontmatter, such as |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
It seems odd that once you access a tfile object you can't then access functions of the file and frontmatter modules that would allow to manipulate it.
For example: if you use 'tp.config.active_file' to get the calling file, you can't then access its frontmatter. You might expect to be able to use a syntax like: 'tp.config.active_file.frontmatter.tags' to fetch details about the file from which the template is called, but currently can't, as far as I can tell.
Beta Was this translation helpful? Give feedback.
All reactions