UNPKG

609 BTypeScriptView Raw
1/// <reference types="node" />
2import { MakeDirectoryOptions, promises as fsPromises } from 'fs';
3export declare function pathExists(path: string): Promise<boolean>;
4export declare function readJSONSync<T = any>(path: string): T;
5export declare function readJSON<T = any>(path: string): Promise<T>;
6export declare function writeJSON<T>(path: string, data: T, replacer?: (this: any, key: string, value: any) => any, space?: string | number): Promise<void>;
7export declare const writeFile: typeof fsPromises.writeFile;
8export declare function mkdir(path: string, options?: MakeDirectoryOptions): Promise<void>;