Skip to content

Vault.getAbstractFileByPath method

Vault › getAbstractFileByPath

Official

Get a file or folder inside the vault at the given path. To check if the return type is a file, use instanceof TFile. To check if it is a folder, use instanceof TFolder.

Signature:

getAbstractFileByPath(path: string): TAbstractFile | null

Parameters:

Parameter Type Description
path string vault absolute path to the folder or file, with extension, case sensitive.

Returns: TAbstractFile | nullthe abstract file, if it's found.

Since: 0.11.11