Fix examples/webpack/README.md. The .mjs extension is necessary. Close #17319

This commit is contained in:
Takashi Tamura 2023-11-23 09:21:34 +09:00
parent 83f0029212
commit 6e7381bc20

View File

@ -27,7 +27,7 @@ otherwise the build is not guaranteed to work correctly.
## Worker loading ## Worker loading
If you are getting the `Setting up fake worker` warning, make sure you are If you are getting the `Setting up fake worker` warning, make sure you are
importing `pdfjs-dist/webpack` which is the zero-configuration method for importing `pdfjs-dist/webpack.mjs` which is the zero-configuration method for
Webpack users. Installing `worker-loader` is no longer necessary. Webpack users. Installing `worker-loader` is no longer necessary.
import * as pdfjsLib from 'pdfjs-dist/webpack'; import * as pdfjsLib from 'pdfjs-dist/webpack.mjs';