(d)
| 79 | let html = ''; |
| 80 | const open = []; |
| 81 | const build = (d) => { |
| 82 | if (d === 0) { |
| 83 | html += '<p>leaf text node without any markup characters</p>'; |
| 84 | return; |
| 85 | } |
| 86 | |
| 87 | html += `<div class="level-${d}">`; |
| 88 | open.push('</div>'); |
| 89 | for (let i = 0; i < breadth; i++) { |
| 90 | build(d - 1); |
| 91 | } |
| 92 | |
| 93 | html += open.pop(); |
| 94 | }; |
| 95 | |
| 96 | build(depth); |
| 97 | return html; |
no outgoing calls
no test coverage detected
searching dependent graphs…