I want to use Mozilla's PDFjs on my Laravel project but it seems that's I didn't find the proper way to implement it, I've installed it, and require it on my app.js file :
// Import the library
import * as pdfjsLib from "pdfjs-dist";
// Import worker
import pdfJSWorkerURL from "pdfjs-dist/build/pdf.worker?url";
// Import whatever modules you need
import { PDFSinglePageViewer, EventBus, PDFLinkService, PDFFindController, PDFScriptingManager } from "pdfjs-dist/web/pdf_viewer";
// Bind the worker for later use
window.pdfJSWorkerURL = pdfJSWorkerURL;