MCPcopy Index your code
hub / github.com/getsentry/sentry-javascript / normalize

Function normalize

packages/core/src/utils/normalize.ts:55–62  ·  view source on GitHub ↗
(input: unknown, depth: number = 100, maxProperties: number = +Infinity)

Source from the content-addressed store, hash-verified

53 */
54// eslint-disable-next-line @typescript-eslint/no-explicit-any
55export function normalize(input: unknown, depth: number = 100, maxProperties: number = +Infinity): any {
56 try {
57 // since we're at the outermost level, we don't provide a key
58 return visit('', input, depth, maxProperties);
59 } catch (err) {
60 return { ERROR: `**non-serializable** (${err})` };
61 }
62}
63
64/** JSDoc */
65export function normalizeToSize<T>(

Callers 15

normalize.test.tsFile · 0.90
normalize.test.tsFile · 0.90
trpcMiddlewareFunction · 0.90
setupFunction · 0.90
safeJoinConsoleArgsFunction · 0.90
serializeEnvelopeFunction · 0.90
normalizeEventFunction · 0.90
logFunction · 0.90

Calls 1

visitFunction · 0.85

Tested by

no test coverage detected