Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FR] Add a handlebar variable for the safe title version of a note #52

Closed
scottmc42 opened this issue Nov 9, 2022 · 1 comment
Closed

Comments

@scottmc42
Copy link

Proposal:
Add {{safeTitle}} as a placeholder in templating notes.

Notes:
In trying to integrate this with Dataview, I'm trying to create a link to the podcast notes I listened to/added notes on for a particular day. But that's proving difficult because I only have access to the original title in my frontmatter, not the "filename safe" version of the note.

For instance, the title of an episode is: "#387: Build All the Things with Pants Build System", but the actual name of the file is "387 Build All the Things with Pants Build System"; missing the # and :.

As a workaround, at least for Dataview, I can use regexreplace(title,"[\\,#%&/{}*<>$'\":@‣|?]", "") to filter out all the same characters. But there may be other situations where someone would want the filename as well as the title of the podcast.

There may also be a workaround using js in Templater, but that seems like a lot of work for something that should already exist.

chhoumann added a commit that referenced this issue Nov 14, 2022
github-actions bot pushed a commit that referenced this issue Nov 14, 2022
# [2.3.0](2.2.0...2.3.0) (2022-11-14)

### Features

* add safeTitle as template tag ([77b0297](77b0297)), closes [#52](#52)
@chhoumann
Copy link
Owner

Added in 2.3.0 :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants