diff --git a/tooling/api/src/dialog.ts b/tooling/api/src/dialog.ts index ed40e4fa4..3308a727f 100644 --- a/tooling/api/src/dialog.ts +++ b/tooling/api/src/dialog.ts @@ -107,6 +107,7 @@ interface MessageDialogOptions { * } else { * // user selected a single file * } + * ``` * * @example Open a selection dialog for directories * ```typescript diff --git a/tooling/api/src/fs.ts b/tooling/api/src/fs.ts index f10b5b935..7370095d2 100644 --- a/tooling/api/src/fs.ts +++ b/tooling/api/src/fs.ts @@ -271,10 +271,10 @@ async function writeTextFile( /** * Writes a byte array content to a file. - * @example Write a binary file to the `$RESOURCEDIR/avatar.png` path + * @example Write a binary file to the `$APPDIR/avatar.png` path * ```typescript * import { writeBinaryFile, BaseDirectory } from '@tauri-apps/api/fs'; - * await writeBinaryFile('avatar.png', new Uint8Array([]), { dir: BaseDirectory.Resource }); + * await writeBinaryFile('avatar.png', new Uint8Array([]), { dir: BaseDirectory.App }); * ``` * * @param path The file path. @@ -290,10 +290,10 @@ async function writeBinaryFile( /** * Writes a byte array content to a file. - * @example Write a binary file to the `$RESOURCEDIR/avatar.png` path + * @example Write a binary file to the `$APPEDIR/avatar.png` path * ```typescript * import { writeBinaryFile, BaseDirectory } from '@tauri-apps/api/fs'; - * await writeBinaryFile({ path: 'avatar.png', contents: new Uint8Array([]) }, { dir: BaseDirectory.Resource }); + * await writeBinaryFile({ path: 'avatar.png', contents: new Uint8Array([]) }, { dir: BaseDirectory.App }); * ``` * * @param file The object containing the file path and contents.