We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5aef6b9 commit 9c013b1Copy full SHA for 9c013b1
packages/snaps-utils/src/json.ts
@@ -32,6 +32,6 @@ export function parseJson<Type extends Json = Json>(json: string) {
32
*/
33
export function getJsonSizeUnsafe(value: Json, encode = false): number {
34
const json = JSON.stringify(value);
35
- // We intentionally don't use `TextEncoder` because of bad performance on React Native.
+ // We intentionally don't use `TextEncoder` by default because of bad performance on React Native.
36
return encode ? new TextEncoder().encode(json).byteLength : json.length;
37
}
0 commit comments