-
Notifications
You must be signed in to change notification settings - Fork 9.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Setting up fake worker failed: "Cannot read property 'WorkerMessageHandler' of undefined" #11990
Comments
Please provide the actual version number when opening an issue.
(Generally speaking, it's always easier/quicker for people if you actually attach screen-shots directly to the issue rather than linking to it.) The screen-shot clearly shows that you haven't setup the PDF.js library correctly, based on the warning messages, since you should always ensure that the pdfjsLib.GlobalWorkerOptions.workerSrc = "../some/path/to/pdf.worker.js"; Finally, please note that this is a bug tracker rather than a support forum and that this issue is missing too many details to be actionable/valid; please also see https://github.com/mozilla/pdf.js/blob/master/.github/CONTRIBUTING.md (emphasis mine):
|
pdfjs-dist: 2.2.228 |
|
I use Pdfjs v2.8.335 with legacy supporting in this way: import * as pdfjsLib from 'pdfjs-dist/legacy/build/pdf' pdfjsLib.GlobalWorkerOptions.workerSrc = PDFJSWorker |
In order not to increase the size of the mobile product dependent package, is there any other way we can solve it? |
Thank you |
Configuration:
Chrome version: 81.0.4044.129
OS: Ubuntu
PDF.js version: Using pdf-dist npm module(https://www.npmjs.com/package/pdfjs-dist)
Is a browser extension: No
Pdf file is: http://www.africau.edu/images/default/sample.pdf
Problem:
I am using a pdf-dist library, It was working correctly, but suddenly got an issue like the following picture
https://snipboard.io/A67H4J.jpg
Could you guys please provide any solution.
The text was updated successfully, but these errors were encountered: