find child node index javascript code example Example: Get child node index Array.from(element.parentNode.children).indexOf(element)