diff --git a/src/display/api.js b/src/display/api.js
index 1236cdc44..cbf4e9a36 100644
--- a/src/display/api.js
+++ b/src/display/api.js
@@ -185,16 +185,6 @@ function setPDFNetworkStreamFactory(pdfNetworkStreamFactory) {
  *   (see `web/debugger.js`). The default value is `false`.
  */
 
-/**
- * @typedef {Object} PDFDocumentStats
- * @property {Object<string, boolean>} streamTypes - Used stream types in the
- *   document (an item is set to true if specific stream ID was used in the
- *   document).
- * @property {Object<string, boolean>} fontTypes - Used font types in the
- *   document (an item is set to true if specific font ID was used in the
- *   document).
- */
-
 /**
  * This is the main entry point for loading a PDF and interacting with it.
  *
@@ -891,6 +881,16 @@ class PDFDocumentProxy {
     return this._transport.downloadInfoCapability.promise;
   }
 
+  /**
+   * @typedef {Object} PDFDocumentStats
+   * @property {Object<string, boolean>} streamTypes - Used stream types in the
+   *   document (an item is set to true if specific stream ID was used in the
+   *   document).
+   * @property {Object<string, boolean>} fontTypes - Used font types in the
+   *   document (an item is set to true if specific font ID was used in the
+   *   document).
+   */
+
   /**
    * @returns {Promise<PDFDocumentStats>} A promise this is resolved with
    *   current statistics about document structures (see