JSON
Less than 1 minute
JSON
Since JSON
object is missed only in very old engines like IE7-, Core-JS does not provide a full JSON
polyfill, however, fix already existing implementations by the current standard, for example, well-formed JSON.stringify
. JSON
also fixed in other modules - for example, Symbol
polyfill fixes JSON.stringify
for correct work with symbols.
Modules
Types
interface JSON {
stringify(
value: any,
replacer?:
| Array<string | number>
| ((key: string, value: any) => any)
| null,
space?: string | number
): string | void;
[Symbol.toStringTag]: "JSON";
}
Entry points
core-js(-pure)/es|stable|actual|full/json/stringify
core-js(-pure)/es|stable|actual|full/json/to-string-tag
Example
JSON.stringify({ "𠮷": ["\uDF06\uD834"] }); // => '{"𠮷":["\\udf06\\ud834"]}'