From 0d08f3606d62987100c941491df2f829ce5a6b6d Mon Sep 17 00:00:00 2001 From: Daniel Micay Date: Sun, 21 Nov 2021 15:39:19 -0500 Subject: [PATCH] explicitly set pdf.js worker to avoid deprecation --- app/src/main/assets/viewer.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/main/assets/viewer.js b/app/src/main/assets/viewer.js index c11db9b..911b4c2 100644 --- a/app/src/main/assets/viewer.js +++ b/app/src/main/assets/viewer.js @@ -1,5 +1,7 @@ "use strict"; +pdfjsLib.GlobalWorkerOptions.workerSrc = "/pdf.worker.js"; + const padding = document.getElementById("padding"); let pdfDoc = null; let pageRendering = false;