(node)
| 76 | |
| 77 | const freq = new Map(); |
| 78 | const snippet = (node) => { |
| 79 | const t = node.text.replace(/\s+/g, ' ').trim(); |
| 80 | return t.length > 48 ? `${t.slice(0, 48)}…` : t; |
| 81 | }; |
| 82 | |
| 83 | function walk(node, depth, fieldName) { |
| 84 | if (node.isNamed) freq.set(node.type, (freq.get(node.type) || 0) + 1); |