MCPcopy Create free account
hub / github.com/Script-Hub-Org/Script-Hub / flattenChildren

Function flattenChildren

Rewrite-Parser.js:3145–3155  ·  view source on GitHub ↗
(children)

Source from the content-addressed store, hash-verified

3143 }
3144
3145 function flattenChildren(children) {
3146 const result = []
3147 if (Array.isArray(children)) {
3148 children.forEach(child => {
3149 result.push(...flattenChildren(child))
3150 })
3151 } else if (children) {
3152 result.push(children)
3153 }
3154 return result
3155 }
3156 return traverseTree(node, platform)
3157}
3158

Callers 1

traverseTreeFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected