canvasMaxAreaInBytes in DocumentInitParameters has type Boolean, preventing TypeScript users from passing the correct (numeric) value.
const messageHandler = new MessageHandler(
            docId,
            workerId,
            worker.port
          );
          const transport = new WorkerTransport(
            messageHandler,
            task,
            networkStream,
            transportParams,
            transportFactory
          );
          task._transport = transport;
          messageHandler.send("Ready", null);
        }
      );
    })
    .catch(task._capability.reject);
  return task;
}
/**
 * Starts fetching of specified PDF document/data.
 *
 * @param {PDFWorker} worker
 * @param {Object} source
 * @returns {Promise<string>} A promise that is resolved when the worker ID of
 *   the `MessageHandler` is known.
 * @private
 */
async function _fetchDocument(worker, source) {