-
I like how the default configuration automatically adds an ID to new notes, but if I go to the Obsidian App and try to view my graph, it looks quite ugly as it only shows the ID's of the notes. Is there a way in the configuration, or in Obsidian, to make it show the aliases or for the notes YAMLs to include a title? I am imagining something like Org Mode's "#+Title:" |
Beta Was this translation helpful? Give feedback.
Answered by
r00t3dd
Jul 10, 2024
Replies: 1 comment 1 reply
-
Hey @UberChili, you can achieve this by adding note_path_func callback in your obsidian.nvim settings. For example: -- Optional, customize how note file names are generated given the ID, target directory, and title.
---@param spec { id: string, dir: obsidian.Path, title: string|? }
---@return string|obsidian.Path The full path to the new note.
note_path_func = function(spec)
-- This is equivalent to the default behavior.
local path = spec.dir / tostring(spec.id) .. "+" .. tostring(spec.title)
return path:with_suffix(".md")
end, Line 320 in e170641 |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
UberChili
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hey @UberChili, you can achieve this by adding note_path_func callback in your obsidian.nvim settings. For example:
obsidian.nvim/README.md
Line 320 in e170641