function recursiveResolve(node) { if (typeof node != 'undefined') { //node.someMethod = aFunction var l = node.childElementCount if (l) { childrens = node.children for (var i = 0; i < l; i++) { recursiveResolve(childrens[i]) } } } }recursiveResolve(document.body)
The problem is that, its not working as expected, it is only resolving until the last <span class="line line-3"></span> and stops there when <section class="presentation"></section> still remaining to be resolved. What i'm doing wrong?
You saved my day!!! Thank you so much!!!