mozilla / pdf.js

PDF Reader in JavaScript
https://mozilla.github.io/pdf.js/
Apache License 2.0
47.09k stars 9.81k forks source link

How to import types from pdfjs-dist/types/web/ in Angular 17? #18294

Closed Tucaen closed 1 week ago

Tucaen commented 1 week ago

Configuration:

Steps to reproduce the problem:

  1. Create a standalone component
  2. Import for example PDFViewer from pdfjs-dist/types/web/pdf_viewer

What is the expected behavior? (add screenshot) Type is used and project builds

What went wrong? (add screenshot) Module not found: Error: Can't resolve 'pdfjs-dist/types/web/pdf_viewer' in 'path/to/standalone.component'