function _maybeAddInsertionPoint(node, parent, root) {
  let added;
  let insertionPointTag = root.getInsertionPointTag();
  if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE &&
    !node['__noInsertionPoint']) {
    let c$ = node.querySelectorAll(insertionPointTag);
    for (let i=0, n, np, na; (i<c$.length) && (n=c$[i]); i++) {
      np = n.parentNode;
      // don't allow node's parent to be fragment itself
      if (np === node) {
        np = parent;
      }
      na = _maybeAddInsertionPoint(n, np, root);
      added = added || na;
    }
  } else if (node.localName === insertionPointTag) {
    recordChildNodes(parent);
    recordChildNodes(node);
    added = true;
  }
  return added;
}
/* note: parent argument is required since node may have an out
of date parent at this point; returns true if a <content> is being added */
parent argument is required since node may have an out
of date parent at this point; returns true if a  is being added
parent argument is required since node may have an out of date parent at this point ; returns true if a is being added
function _maybeAddInsertionPoint(node, parent, root) {
  let added;
  let insertionPointTag = root.getInsertionPointTag();
  if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE &&
    !node['__noInsertionPoint']) {
    let c$ = node.querySelectorAll(insertionPointTag);
    for (let i=0, n, np, na; (i<c$.length) && (n=c$[i]); i++) {
      np = n.parentNode;
      if (np === node) {
        np = parent;
      }
      na = _maybeAddInsertionPoint(n, np, root);
      added = added || na;
    }
  } else if (node.localName === insertionPointTag) {
    recordChildNodes(parent);
    recordChildNodes(node);
    added = true;
  }
  return added;
}
function _maybeAddInsertionPoint ( node , parent , root ) { let added ; let insertionPointTag = root . getInsertionPointTag ( ) ; if ( node . nodeType === Node . DOCUMENT_FRAGMENT_NODE && ! node [ '__noInsertionPoint' ] ) { let c$ = node . querySelectorAll ( insertionPointTag ) ; for ( let i = 0 , n , np , na ; ( i < c$ . length ) && ( n = c$ [ i ] ) ; i ++ ) { np = n . parentNode ; if ( np === node ) { np = parent ; } na = _maybeAddInsertionPoint ( n , np , root ) ; added = added || na ; } } else if ( node . localName === insertionPointTag ) { recordChildNodes ( parent ) ; recordChildNodes ( node ) ; added = true ; } return added ; }
note: parent argument is required since node may have an out
of date parent at this point; returns true if a <content> is being added
note : parent argument is required since node may have an out of date parent at this point ; returns true if a <content > is being added
// don't allow node's parent to be fragment itself