leshi-ui
Version:
Modern CLI for building and managing React Native UI components with copy-paste simplicity, custom theming, and open source design system support
17 lines (16 loc) • 855 B
TypeScript
export declare class FileUtils {
static exists(filePath: string): Promise<boolean>;
static ensureDir(dirPath: string): Promise<void>;
static copy(src: string, dest: string, overwrite?: boolean): Promise<void>;
static readFile(filePath: string): Promise<string>;
static writeFile(filePath: string, content: string): Promise<void>;
static readJson<T>(filePath: string): Promise<T>;
static writeJson(filePath: string, data: unknown): Promise<void>;
static isDirectory(dirPath: string): Promise<boolean>;
static listFiles(dirPath: string): Promise<string[]>;
static getRelativePath(from: string, to: string): string;
static join(...paths: string[]): string;
static dirname(filePath: string): string;
static basename(filePath: string, ext?: string): string;
static resolve(...paths: string[]): string;
}