用的是pdf.js,引用如下
pdfjsLib输出为undefined版本 "pdfjs-dist": "^2.2.228"
不好意思,自问自答 改用require
const pdfjsLib = require('pdfjs-dist'); pdfjsLib.GlobalWorkerOptions.workerSrc = require('pdfjs-dist/build/pdf.worker.entry');
是突然在一篇博客看到的:https://blog.csdn.net/xss392795158/article/details/108079627
1.4m articles
1.4m replys
5 comments
57.0k users