Skip to content

NoteComposerPluginInstance.mergeFile method

NoteComposerPluginInstance › mergeFile

Unofficial

Merge a source note into a target note, apply the merge template, update links and trash the source.

Signature:

mergeFile(target: TFile, source: TFile, mode?: 'append' | 'prepend'): Promise<void>

Parameters:

ParameterTypeDescription
targetTFileThe note receiving the merged content.
sourceTFileThe note to merge and trash.
mode?'append' | 'prepend'Where to insert the content. Defaults to 'append'.

Returns: Promise<void> — A promise that resolves when the merge and link updates complete.