How to Delete pages from pdf file in JavaScript

Posted by

we need JavaScript libraries:

pdf.js: “https://cdnjs.cloudflare.com/ajax/libs/pdf.js/2.12.313/pdf.min.js”

pdf-lib: “https://unpkg.com/pdf-lib@1.3.0” //This library helps to delete pages.

downloadjs: “https://unpkg.com/downloadjs@1.4.7” //use for download attachment

Make a index.html file

save and run to the browser

After selecting pdf file it shows pages number, then select pages which you want to delete

0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x