starter icon indicating copy to clipboard operation
starter copied to clipboard

Doesn't work with next js 14

Open Andmarecoenergy opened this issue 11 months ago • 1 comments

Module not found: Can't resolve 'pdfjs-dist/build/pdf.worker.mjs' 81 | // We import this here so that it's only loaded during client-side rendering. 82 | const pdfJS = await import("pdfjs-dist");

83 | pdfJS.GlobalWorkerOptions.workerSrc = require("pdfjs-dist/build/pdf.worker.mjs"); | ^ 84 | const pdf = await pdfJS.getDocument(templateBytes).promise; 85 | 86 | setTotalPages(pdf.numPages);

https://nextjs.org/docs/messages/module-not-found

Andmarecoenergy avatar Mar 22 '24 20:03 Andmarecoenergy