MCPcopy Create free account
hub / github.com/docker/getting-started / _toPrimitive

Function _toPrimitive

app/src/static/js/react-bootstrap.js:1247–1258  ·  view source on GitHub ↗
(input, hint)

Source from the content-addressed store, hash-verified

1245}
1246
1247function _toPrimitive(input, hint) {
1248 if (typeof input !== "object" || input === null) return input;
1249 var prim = input[Symbol.toPrimitive];
1250
1251 if (prim !== undefined) {
1252 var res = prim.call(input, hint || "default");
1253 if (typeof res !== "object") return res;
1254 throw new TypeError("@@toPrimitive must return a primitive value.");
1255 }
1256
1257 return (hint === "string" ? String : Number)(input);
1258}
1259
1260function useUncontrolled(props, config) {
1261 return Object.keys(config).reduce(function (result, fieldName) {

Callers 1

_toPropertyKeyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…