UNPKG

cli-diff

Version:

A diff utility with highlighted output for CLIs

17 lines (16 loc) 585 B
export interface File { name?: string; content: string; header?: string; } export interface Options { context: number; } /** * Create a ANSI-highlighted diff between the two provided files * @param oldFile The original file. Can be passed as an object or as a plain string. * @param newFile The new file. Can be passed as an object or as a plain string. * @param options (optional) options to pass to JSDiff * @return The ANSI-highlighted diff */ export default function diff(oldFile: File | string, newFile: File | string, options?: Options): string;