src/service/performance-impl.js
/**
   * Returns a promise that is resolved when resources in viewport
   * have been finished being laid out.
   * @return {!Promise}
   * @private
   */
Returns a promise that is resolved when resources in viewport
have been finished being laid out.
@return {!Promise}
@private
Returns a promise that is resolved when resources in viewport have been finished being laid out . @return { !Promise } @private
whenViewportLayoutComplete_() {
    const size = Services.viewportForDoc(this.win.document).getSize();
    const rect = layoutRectLtwh(0, 0, size.width, size.height);
    return this.resources_.getResourcesInRect(
        this.win, rect,  true)
        .then(resources => Promise.all(resources.map(r => r.loadedOnce())));
  }
whenViewportLayoutComplete_ ( ) { const size = Services . viewportForDoc ( this . win . document ) . getSize ( ) ; const rect = layoutRectLtwh ( 0 , 0 , size . width , size . height ) ; return this . resources_ . getResourcesInRect ( this . win , rect , true ) . then ( resources => Promise . all ( resources . map ( r => r . loadedOnce ( ) ) ) ) ; }
Returns a promise that is resolved when resources in viewport
 have been finished being laid out.
Returns a promise that is resolved when resources in viewport have been finished being laid out .
/* isInPrerender */