import type { Abortable } from "node:events";
import type { WriteFileOptions as FSWriteFileOptions, Mode, ObjectEncodingOptions, OpenMode } from "node:fs";
import type { Encoding } from "./constants";
export interface WriteFileOptions {
    /**
     * Whether to create the directory if it does not exist
     *
     * @defaultValue true
     */
    createDirectory?: boolean;
}
/**
 * Write the given content to the given file path
 *
 * @param filePath - The file path to write to
 * @param content - The content to write to the file
 */
export declare const writeFileSync: (filePath: string, content?: string, options?: WriteFileOptions & FSWriteFileOptions) => void;
/**
 * Read the given content to the given file path
 *
 * @param filePath - The file path to read to
 * @param content - The content to write to the file
 * @returns The content of the file
 */
export declare const writeFile: (filePath: string, content?: string, options?: WriteFileOptions & ((ObjectEncodingOptions & {
    mode?: Mode | undefined;
    flag?: OpenMode | undefined;
    flush?: boolean | undefined;
} & Abortable) | Encoding)) => Promise<void>;
