Alcumus / react-doc-viewer

Apache License 2.0
208 stars 101 forks source link

ERROR in ./node_modules/react-pdf/dist/esm/eventBus.js #68

Open anasyo10 opened 3 years ago

anasyo10 commented 3 years ago

Hi, I am getting this error when I am using the package on my rails react app,

"export 'EventBus' was not found in 'pdfjs-dist/lib/web/ui_utils'

It's a simple import not anything fancy

import DocViewer from "react-doc-viewer";

const docs = [
    { uri: "http://www.orimi.com/pdf-test.pdf" },
  ];

  <DocViewer documents={docs} />

Would appreciate any help on this.

My rails version is 5.2.3 My react version is 16.3.0 My node version is 13.7.0

I am using yarn instead of npm as it goes with my project. Using webpack to compile the JS.

Thanks

yusuf-khamis commented 2 years ago

did you ever figure this out??