obsidian-hotkeys-for-templates icon indicating copy to clipboard operation
obsidian-hotkeys-for-templates copied to clipboard

Cannot configure the plugin in Preferences

Open jdheyburn opened this issue 1 year ago • 4 comments

Hey

Firstly thanks for making this plugin. It's super useful to be able to assign to a hotkey the ability to create a new file in a location for a template.

It's been a while since I've had to touch the settings for this so apologies if I am using it wrong. I noticed that the settings for the plugin in the Obsidian preferences was empty.

image

I am using the latest version of the plugin, and I am running Obsidian v1.4.3.

Please let me know if you need any more info, thank you!

jdheyburn avatar Aug 17 '23 10:08 jdheyburn

I'm as well on Obsidian 1.4.3, but have no issues. Please open the console (CTRL + SHIFT + I) and share a screenshot of the appearing error.

Vinzent03 avatar Aug 18 '23 13:08 Vinzent03

Clicked both in and out of focus of the plugin preferences page, and got only this error when focusing on Hotkeys for templates:

Btw I am on MacOS Apple Silicon

Uncaught TypeError: Cannot read properties of undefined (reading 'replace')
    at pe (app.js:1:246501)
    at Module.he (app.js:1:246422)
    at HotkeysForTemplates.enumerateTemplates (plugin:obsidian-hotkeys-for-templates:2269:51)
    at SettingsTab.display (plugin:obsidian-hotkeys-for-templates:2508:21)
    at t.openTab (app.js:1:2728486)
    at HTMLDivElement.<anonymous> (app.js:1:2726925)
p

jdheyburn avatar Aug 18 '23 13:08 jdheyburn

I think I found the reason. Please specify the templates folder in the settings of the core templates plugin. If that fixes it, I will fix the check that should prevent that.

Vinzent03 avatar Aug 18 '23 14:08 Vinzent03

That fixed it! Thank you - I didn't even know that was missing 🎉

jdheyburn avatar Aug 18 '23 14:08 jdheyburn