MCPcopy Index your code
hub / github.com/dataease/SQLBot / forEachPrimitive

Function forEachPrimitive

frontend/public/swagger-ui-bundle.js:39058–39067  ·  view source on GitHub ↗
(s, o, i)

Source from the content-addressed store, hash-verified

39056 flatten(s.filter(isAdditiveMutation).map((s) => o(s.value, i, s.path)) || [])
39057 )
39058 }
39059 function forEachPrimitive(s, o, i) {
39060 return (
39061 (i = i || []),
39062 Array.isArray(s)
39063 ? s.map((s, a) => forEachPrimitive(s, o, i.concat(a)))
39064 : lib_isObject(s)
39065 ? Object.keys(s).map((a) => forEachPrimitive(s[a], o, i.concat(a)))
39066 : o(s, i[i.length - 1], i)
39067 )
39068 }
39069 function forEach(s, o, i) {
39070 let a = []

Callers

nothing calls this directly

Calls 6

lib_isObjectFunction · 0.85
concatMethod · 0.80
oFunction · 0.70
isArrayMethod · 0.45
mapMethod · 0.45
keysMethod · 0.45

Tested by

no test coverage detected