Closed NomarCub closed 11 months ago
Not sure if I understood correctly but if you want to dispatch a reveal active file event from the Context menu you have from the plugin:
let fileToReveal = app.vault.getAbstractFileByPath(ANYFILEPATH); // or you don't need it if you already have TFile or TAbstractFile variable
let revealFileEvent = new CustomEvent({
'fta-reveal-file',
detail: {
file: fileToReveal,
},
});
window.dispatchEvent(revealFileEvent);
I want to make context menu using this plugin's features: https://github.com/NomarCub/obsidian-copy-url-in-preview/issues/29 How would I go about it?