From edf6e6cec1460c4383e7b0f1d655238b7df678a5 Mon Sep 17 00:00:00 2001 From: Daniel Fjeldstad <45217974+w3bdesign@users.noreply.github.com> Date: Thu, 30 May 2024 21:11:32 +0200 Subject: [PATCH] Update PDFViewer.component.tsx --- src/components/CV/PDFViewer.component.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/CV/PDFViewer.component.tsx b/src/components/CV/PDFViewer.component.tsx index 78e19fef..9a61c4d5 100644 --- a/src/components/CV/PDFViewer.component.tsx +++ b/src/components/CV/PDFViewer.component.tsx @@ -6,7 +6,8 @@ import { Document, Page, pdfjs } from "react-pdf"; import "react-pdf/dist/esm/Page/AnnotationLayer.css"; import "react-pdf/dist/esm/Page/TextLayer.css"; -pdfjs.GlobalWorkerOptions.workerSrc = `//unpkg.com/pdfjs-dist@${pdfjs.version}/build/pdf.worker.min.js`; +//pdfjs.GlobalWorkerOptions.workerSrc = `//unpkg.com/pdfjs-dist@${pdfjs.version}/build/pdf.worker.min.js`; +pdfjs.GlobalWorkerOptions.workerSrc = `//unpkg.com/pdfjs-dist@${pdfjs.version}/build/pdf.min.mjs`; type PdfViewerProps = { file: string };