pdfjs icon indicating copy to clipboard operation
pdfjs copied to clipboard

Add dist folder to NPM releases

Open rohitdharavath opened this issue 6 years ago • 5 comments

rohitdharavath avatar Nov 14 '17 19:11 rohitdharavath

Hi, since most users use a build tool to build their frontend code anyway, the module does currently not contain a single-build file. But this is maybe something I should add. If you want to create a single-file bundle of pdfjs, you could probably reuse the code from https://github.com/rkusa/pdfjs/tree/master/playground for now.

rkusa avatar Nov 15 '17 15:11 rkusa

I'd really appreciate a transpiled version of this module too… maybe in a dist folder?

bummzack avatar Jul 07 '18 10:07 bummzack

Will be part of #87

rkusa avatar Feb 08 '19 15:02 rkusa

Hi @rkusa, I am trying to upgrade from version 1.x to the up to date version (client-side).

I tried yarn install + yarn build (es6-modules branch) and it builds dist-src and dist-node in pkg, but when I use dist-src, this error appears:

Uncaught TypeError: Failed to resolve module specifier "stream"

Seems, the dependencies do not get into the build

How can I solve this?

DmitriySlabodchikov avatar Jul 13 '21 11:07 DmitriySlabodchikov

Hi @DmitriySlabodchikov, are you by any chance using webpack 5? I haven't used pdfjs with webpack5 yet, but the error sounds like it could be because of webpack 5 removed automatic Node.js polyfills. If this is the case, the solution would be to manually add a polyfill for stream for now.

rkusa avatar Jul 29 '21 08:07 rkusa