MCPcopy Index your code
hub / github.com/codeceptjs/CodeceptJS / collectSummaries

Function collectSummaries

lib/aria.js:192–200  ·  view source on GitHub ↗
(nodes)

Source from the content-addressed store, hash-verified

190
191// Walk tree, emit one summary string per meaningful interactive node.
192function collectSummaries(nodes) {
193 return nodes.flatMap(node => {
194 const fromChildren = collectSummaries(node.children)
195 if (!INTERACTIVE_ROLES.has(node.role)) return fromChildren
196 const summary = formatNode(node)
197 if (summary === node.role) return fromChildren // skip empty unnamed interactive nodes
198 return [summary, ...fromChildren]
199 })
200}
201
202function countBy(items) {
203 return items.reduce((map, item) => {

Callers 1

summariesOfFunction · 0.85

Calls 1

formatNodeFunction · 0.85

Tested by

no test coverage detected