example-d3/webworker.js
/** Returns the previous node in document order (excluding attributes
   * and namespace nodes).
   */
Returns the previous node in document order (excluding attributes
and namespace nodes).
Returns the previous node in document order ( excluding attributes and namespace nodes ) .
function precedingNode(node) {
    if (node.ownerElement)
      return node.ownerElement;
    if (null != node.previousSibling) {
      node = node.previousSibling;
      while (null != node.lastChild) {
        node = node.lastChild;
      }
      return node;
    }
    if (null != node.parentNode) {
      return node.parentNode;
    }
    return null;
  }
function precedingNode ( node ) { if ( node . ownerElement ) return node . ownerElement ; if ( null != node . previousSibling ) { node = node . previousSibling ; while ( null != node . lastChild ) { node = node . lastChild ; } return node ; } if ( null != node . parentNode ) { return node . parentNode ; } return null ; }
Returns the previous node in document order (excluding attributes
 and namespace nodes).
Returns the previous node in document order ( excluding attributes and namespace nodes ) .