MCPcopy Index your code
hub / github.com/angular/angular / formatValue

Function formatValue

packages/core/src/render3/errors.ts:88–100  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

86}
87
88function formatValue(value: unknown): string {
89 let strValue: string = String(value);
90
91 // JSON.stringify will throw on circular references
92 try {
93 if (Array.isArray(value) || strValue === '[object Object]') {
94 strValue = JSON.stringify(value);
95 }
96 } catch (error) {}
97 return strValue.length > VALUE_STRING_LENGTH_LIMIT
98 ? strValue.substring(0, VALUE_STRING_LENGTH_LIMIT) + '…'
99 : strValue;
100}
101
102function constructDetailsForInterpolation(
103 lView: LView,

Callers 1

Calls 1

isArrayMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…