MCPcopy Create free account
hub / github.com/binux/qiandao / stringifyPrimitive

Function stringifyPrimitive

web/static/node_components.js:2056–2070  ·  view source on GitHub ↗
(v)

Source from the content-addressed store, hash-verified

2054'use strict';
2055
2056var stringifyPrimitive = function(v) {
2057 switch (typeof v) {
2058 case 'string':
2059 return v;
2060
2061 case 'boolean':
2062 return v ? 'true' : 'false';
2063
2064 case 'number':
2065 return isFinite(v) ? v : '';
2066
2067 default:
2068 return '';
2069 }
2070};
2071
2072module.exports = function(obj, sep, eq, name) {
2073 sep = sep || '&';

Callers 1

node_components.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected