Yes absolutely you can use it offline. Download the latest version here.
Now extract the zip file and put it on a server(use xampp/wamp/lamp or any other localhost) because the worker is not enabled for file:// urls.
To show the pdf files traverse to web/viewer.html from the localhost and it should load its default pdf.
As to the question about how to show your pdf's use: viewer.html?file=relative/path/to/your/pdf
Say for example inside the web folder(the one in which viewer.html is there) of your pdf.js you create a directory say named pdfFiles
and in it you add a pdf named say mypdf.pdf
in it then to display it use: viewer.html?file=pdfFiles/mypdf.pdf
and it will display it.
Look here for more details on how to dynamically assign PDF file paths to the viewer. If you have any other queries let me know. I have used pdf.js offline and it works wonderfully on almost all the browsers I know.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…