a
b
c
{"ScriptPreparationCode":"var parent = document.getElementById(\u0027test\u0027);\r\n\r\nvar store1 = [];\r\nvar store2 = [];\r\nparent.childNodes.forEach(function (node) {\r\n if ( node.nodeName !== \u0027#text\u0027) {\r\n store1.push( node );\r\n store2.push( { name: node.attributes.name.value } );\r\n }\r\n});","TestCases":[{"Name":"fastest iter childelements","Code":"let elem = parent.firstElementChild;\r\ndo {\r\n let n = elem.attributes.name.value;\r\n} while (elem = elem.nextElementSibling)","IsDeferred":false},{"Name":"tag name","Code":"let children = parent.getElementsByTagName(\u0027div\u0027);\r\nfor (let i = 0; i \u003C children.length; i\u002B\u002B) {\r\n let n = children[i].attributes.name.value;\r\n}","IsDeferred":false},{"Name":"class name","Code":"let children = parent.getElementsByClassName(\u0027item\u0027)\r\nfor (let i = 0; i \u003C children.length; i\u002B\u002B) {\r\n let n = children[i].attributes.name.value;\r\n}","IsDeferred":false},{"Name":"id","Code":"let n1 = document.getElementById(\u0027a\u0027).attributes.name.value;\r\nlet n2 = document.getElementById(\u0027b\u0027).attributes.name.value;\r\nlet n3 = document.getElementById(\u0027c\u0027).attributes.name.value;","IsDeferred":false},{"Name":"array of node","Code":"for (let i = 0; i \u003C store1.length; i\u002B\u002B) {\r\n let n = store1[i].attributes.name.value;\r\n}","IsDeferred":false},{"Name":"array item","Code":"for (let i = 0; i \u003C store2.length; i\u002B\u002B) {\r\n let n = store2[i].name;\r\n}","IsDeferred":false},{"Name":"fastest iter childelements \u002B getAttribute","Code":"let elem = parent.firstElementChild;\r\ndo {\r\n let n = elem.getAttribute(\u0027name\u0027);\r\n} while (elem = elem.nextElementSibling)\r\n","IsDeferred":false},{"Name":"fastest iter childelements \u002B nodeValue","Code":"let elem = parent.firstElementChild;\r\ndo {\r\n let n = elem.nodeValue;\r\n} while (elem = elem.nextElementSibling)","IsDeferred":false},{"Name":"fastest iter childelements \u002B textContent","Code":"let elem = parent.firstElementChild;\r\ndo {\r\n let n = elem.textContent;\r\n} while (elem = elem.nextElementSibling)","IsDeferred":false},{"Name":"fastest iter childelements \u002B getAttributeNode","Code":"let elem = parent.firstElementChild;\r\ndo {\r\n let n = elem.getAttributeNode(\u0027name\u0027).value;\r\n} while (elem = elem.nextElementSibling)","IsDeferred":false}]}