Using PDF.js Express with NPM on WeWeb

Which product are you using?
PDF.js Express Viewer

PDF.js Express Version
8.7.5

Detailed description of issue
I’m trying to integrate PDF.js Express Viewer into WeWeb, a no-code/low-code platform. Ideally, I’d like to install it directly from NPM instead of using a Vue component. However, I’ve heard that PDF.js Express expects the code to be loaded locally within the app, which might make it incompatible with WeWeb’s NPM setup.

Some key questions:

  1. Can PDF.js Express work via WeWeb’s NPM integration, or does it require a custom code component?
  2. Are there specific workarounds to make it function properly in a no-code/low-code environment like WeWeb?
  3. Does it support CDN-based loading (which WeWeb handles well)?

Any insights or best practices would be greatly appreciated!

Thanks in advance.

Expected behaviour
Get a preview of a pdf documents.

Does your issue happen with every document, or just one?
Yes. I cannot get the preview

Link to document
n/a
Code snippet
n/a

Hello emdi,

  1. I haven’t come across any of our users using WeWeb’s NPM integration. We have another PDF viewer similar to PDF.js Express that can run on Salesforce, which is also a low-code platform, but it required customization on our end.

  2. Unfortunately, there are no workarounds that I am aware of.

  3. Are you talking about loading the lib folder from another domain? This is possible. Please review the Load PDF.js Express Viewer from another domain section. What is PDF.js Express? | Documentation

Best Regards,
Darian