Skip to content

EditableFileView.saveTitle method

EditableFileView › saveTitle

Unofficial

Updates the file to match the updated title.

Signature:

saveTitle(titleEl: HTMLElement): Promise<boolean>

Parameters:

ParameterTypeDescription
titleElHTMLElementThe current title element.

Returns: Promise<boolean> — A promise that resolves to false when the new name is invalid and the error is shown on the title, keeping the rename open; to true when the file was renamed, or when no rename of this view's file is active.