code: function getElementIndex(headingEl) {
      return Array.prototype.slice.call(headingEl.parentNode.children).indexOf(headingEl);
  }
docs: Get 0-based index of element within its parent
  @param {HTMLElement} headingEl