function isLeftEdgeOf(node, ancestor) {
  while (node && node !== ancestor) {
    if (position(node) !== 0) {
      return false;
    }
    node = node.parentNode;
  }

  return true;
}
returns whether node is left edge of ancestor or not.

@param {Node} node
@param {Node} ancestor
@return {Boolean}