Skip to content

createFolderSafe

Creates a folder safely in the specified path.

Import:

import { createFolderSafe } from 'obsidian-dev-utils/obsidian/vault';

Signature:

function createFolderSafe(app: App, path: string): Promise<boolean>

Parameters:

ParameterTypeDescription
appAppThe application instance.
pathstringThe path of the folder to create.

Returns: Promise<boolean> — A Promise that resolves to a boolean indicating whether the folder was created.