npm.io
1.0.3 • Published 2 years ago

@types/json-parse-better-errors

Licence
MIT
Version
1.0.3
Deps
0
Size
4 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/json-parse-better-errors

Summary

This package contains type definitions for json-parse-better-errors (https://github.com/zkat/json-parse-better-errors#readme).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/json-parse-better-errors.

index.d.ts

export = json_parse_better_errors;

/**
 * Converts a JavaScript Object Notation (JSON) string into an object.
 * @param text A valid JSON string.
 * @param reviver A function that transforms the results. This function is called for each member of the object.
 *               If a member contains nested objects, the nested objects are transformed before the parent object is.
 * @param context The number of characters to display in each direction around the position of an error.
 */
declare function json_parse_better_errors(
    txt: string,
    reviver?: (key: string, value: any) => any,
    context?: number,
): any;

Additional Details

  • Last updated: Tue, 07 Nov 2023 0337 GMT
  • Dependencies: none

Credits

These definitions were written by Daniel Rosenwasser.