Files
SnowLuma/.pnpm-store/v11/files/2f/1dac8aeb6170b8eff012fd02020d71479ad56433d79cfd7b5bb10d6ac678bfa5d25c5710820c12910a548729c77eb2d98e88e96b1667bcb77d48ba89d8ecb5
T
TanTan 2a69b23b47
Dev Build / cleanup (push) Waiting to run
Dev Build / typecheck (push) Waiting to run
docs: 仓库链接指向本镜像仓库
2026-11-13 09:27:07 +08:00

33 lines
1.5 KiB
Plaintext

export { JSON5ParseOptions, JSON5StringifyOptions, parseJSON5, stringifyJSON5 } from './json5.js';
export { JSONCParseError, JSONCParseOptions, parseJSONC, stringifyJSONC } from './jsonc.js';
export { YAMLParseOptions, YAMLStringifyOptions, parseYAML, stringifyYAML } from './yaml.js';
import { F as FormatOptions } from './shared/confbox.9745c98f.js';
export { parseTOML, stringifyTOML } from './toml.js';
/**
* Converts a [JSON](https://www.json.org/json-en.html) string into an object.
*
* Indentation status is auto-detected and preserved when stringifying back using `stringifyJSON`
*/
declare function parseJSON<T = unknown>(text: string, options?: JSONParseOptions): T;
/**
* Converts a JavaScript value to a [JSON](https://www.json.org/json-en.html) string.
*
* Indentation status is auto detected and preserved when using value from parseJSON.
*/
declare function stringifyJSON(value: any, options?: JSONStringifyOptions): string;
interface JSONParseOptions extends FormatOptions {
/**
* A function that transforms the results. This function is called for each member of the object.
*/
reviver?: (this: any, key: string, value: any) => any;
}
interface JSONStringifyOptions extends FormatOptions {
/**
* A function that transforms the results. This function is called for each member of the object.
*/
replacer?: (this: any, key: string, value: any) => any;
}
export { type JSONParseOptions, type JSONStringifyOptions, parseJSON, stringifyJSON };