src/service/vsync-impl.js
/**
   * Runs vsync task: measure followed by mutate. Returns the promise that
   * will be resolved as soon as the task has been completed.
   *
   * If state is not provided, the value passed to the measure and mutate
   * will be undefined.
   *
   * @param {!VsyncTaskSpecDef} task
   * @param {!VsyncStateDef=} opt_state
   * @return {!Promise}
   */
Runs vsync task: measure followed by mutate. Returns the promise that
will be resolved as soon as the task has been completed.

If state is not provided, the value passed to the measure and mutate
will be undefined.


Runs vsync task : measure followed by mutate . Returns the promise that will be resolved as soon as the task has been completed . If state is not provided the value passed to the measure and mutate will be undefined .
runPromise(task, opt_state) {
    this.run(task, opt_state);
    if (this.nextFramePromise_) {
      return this.nextFramePromise_;
    }
    return this.nextFramePromise_ = new Promise(resolve => {
      this.nextFrameResolver_ = resolve;
    });
  }
runPromise ( task , opt_state ) { this . run ( task , opt_state ) ; if ( this . nextFramePromise_ ) { return this . nextFramePromise_ ; } return this . nextFramePromise_ = new Promise ( resolve => { this . nextFrameResolver_ = resolve ; } ) ; }
Runs vsync task: measure followed by mutate.
Runs vsync task : measure followed by mutate .