Improves plugin directory path handling dynamically
Updates file path resolution to use plugin manifest directory dynamically Replaces hardcoded plugin directory paths with more flexible approach - Uses `this.manifest.dir!` to determine plugin directory - Supports better cross-platform and installation compatibility - Removes static path references in multiple plugin components Enhances plugin robustness by making directory paths more configurable
This commit is contained in:
4 files changed
+22
-17
No files matched your search
@@ -16,7 +16,8 @@ export class TemplateManager {
|
||||
// Templates are stored in the plugin directory
|
||||
this.templatesPath = path.join(
|
||||
(this.plugin.app.vault.adapter as any).basePath,
|
||||
'.obsidian/plugins/typst-pdf-export/templates'
|
||||
this.plugin.manifest.dir!,
|
||||
'templates'
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user