UNPKG

tools-mock

Version:

A node.js mock tool to quickly start the server via http

13 lines (12 loc) 700 B
/// <reference types="node" /> import * as fs from 'fs'; export default class FileUtil { static copyFile(source: string, destination: string): Promise<void>; static copyFolder(source: string, destination: string): Promise<void>; static deleteFileOrDirectory: (filePath: string) => void; static readFile(filePath: string, nobuffer?: any): Promise<any>; static readDirectory(directoryPath: string, fileCallback?: (filePath: string) => void): Promise<void>; static writeFile(filePath: string, content: any, options?: fs.WriteFileOptions): Promise<void>; static exists(filePath: string, create?: boolean): Promise<boolean>; static getSuffix(url: string): string | null; }