MCPcopy Index your code
hub / github.com/angular-ui/ui-grid / stringify

Function stringify

lib/test/angular/1.6.7/angular.js:2181–2200  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

2179}
2180
2181function stringify(value) {
2182 if (value == null) { // null || undefined
2183 return '';
2184 }
2185 switch (typeof value) {
2186 case 'string':
2187 break;
2188 case 'number':
2189 value = '' + value;
2190 break;
2191 default:
2192 if (hasCustomToString(value) && !isArray(value) && !isDate(value)) {
2193 value = value.toString();
2194 } else {
2195 value = toJson(value);
2196 }
2197 }
2198
2199 return value;
2200}
2201
2202var NODE_TYPE_ELEMENT = 1;
2203var NODE_TYPE_ATTRIBUTE = 2;

Callers 2

angular.jsFile · 0.70

Calls 4

hasCustomToStringFunction · 0.70
isDateFunction · 0.70
toJsonFunction · 0.70
isArrayFunction · 0.50

Tested by

no test coverage detected