MCPcopy Create free account
hub / github.com/adobe/react-spectrum / walk

Function walk

packages/dev/s2-docs/scripts/generateAgentSkills.mjs:308–322  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

306 };
307
308 const walk = node => {
309 if (!node || !Array.isArray(node.children)) {
310 return;
311 }
312
313 for (const child of node.children) {
314 if (child.type === 'listItem') {
315 const entry = extractEntry(child);
316 if (entry) {
317 entries.push(entry);
318 }
319 }
320 walk(child);
321 }
322 };
323
324 walk(tree);
325 return entries;

Callers 2

parseLlmsTxtFunction · 0.70
collectSkillFilesFunction · 0.70

Calls 2

extractEntryFunction · 0.85
pushMethod · 0.80

Tested by

no test coverage detected