1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-06-27 23:28:38 +02:00

Plugins: Add support for plugins.dataDir function, to provide a path for plugin to store its own data

This commit is contained in:
Laurent Cozic
2021-01-24 15:51:35 +00:00
parent 257cde4383
commit cbd842c268
7 changed files with 55 additions and 15 deletions

View File

@ -58,12 +58,11 @@ export default class JoplinPlugins {
return this.plugin.registerContentScript(type, id, scriptPath);
}
// public async onMessage(callback: any) {
// this.plugin.onMessage(callback);
// }
// public async onContentScriptMessage(id: string, callback: any) {
// this.plugin.onContentScriptMessage(id, callback);
// }
/**
* Gets the plugin own data directory path. Use this to store any plugin-related data.
*/
public async dataDir(): Promise<string> {
return this.plugin.dataDir();
}
}