@visulima/fs
Version:
Human friendly file system utilities for Node.js
6 lines (5 loc) • 372 B
TypeScript
import type { JsonValue } from "type-fest";
import type { JsonReviver, ReadJsonOptions } from "../types.d.ts";
declare function readJson<T extends JsonValue>(path: URL | string, options?: ReadJsonOptions): Promise<T>;
declare function readJson<T extends JsonValue>(path: URL | string, reviver: JsonReviver, options?: ReadJsonOptions): Promise<T>;
export default readJson;