The pdfPreview.tsx, I follow code is: https://codesandbox.io/s/react-pdf-v6-itjfzl?file=/src/App.js
But see this error. Any help?
ERROR Failed to compile with 1 errors 17:18:17
error in ./node_modules/react-pdf/node_modules/pdfjs-dist/build/pdf.js
Module parse failed: Unexpected character '#' (1413:9)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|
| class PDFDocumentLoadingTask {
static #docId = 0;
|
| constructor() {
@ ./node_modules/react-pdf/dist/esm/entry.js 1:0-46 7:0-25 8:0-42
@ ./src/pages/POS/SaleOrders/online/pdfPreview.tsx
@ ./src/pages/POS/SaleOrders/index.tsx
@ ./src/pages/.umi/router.js
@ ./src/pages/.umi/umi.js
@ multi ./node_modules/af-webpack/lib/webpackHotDevClient.js ./src/pages/.umi/umi.js
The pdfPreview.tsx, I follow code is: https://codesandbox.io/s/react-pdf-v6-itjfzl?file=/src/App.js
But see this error. Any help?
ERROR Failed to compile with 1 errors 17:18:17
error in ./node_modules/react-pdf/node_modules/pdfjs-dist/build/pdf.js
Module parse failed: Unexpected character '#' (1413:9)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|
| class PDFDocumentLoadingTask {
@ ./node_modules/react-pdf/dist/esm/entry.js 1:0-46 7:0-25 8:0-42
@ ./src/pages/POS/SaleOrders/online/pdfPreview.tsx
@ ./src/pages/POS/SaleOrders/index.tsx
@ ./src/pages/.umi/router.js
@ ./src/pages/.umi/umi.js
@ multi ./node_modules/af-webpack/lib/webpackHotDevClient.js ./src/pages/.umi/umi.js