Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
browser-pdf-to-images
Advanced tools
convert pdf pages to images
import { file2images } from 'browser-pdf-to-images'
file2images(input.files[0]).then(images=>console.log(images))
// ['data:image/png;base64,/9j/4AAQSkZJRg...','data:image/png;base64,/9j/4AAQSkZJRg...']
file2images(file,options={})
options.type
and options.quality
if you want to change output image type and quality
same as https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toDataURL
file2images(file,{
type: 'image/jpeg', // jpg format
quality: 1 // full quality
})
options.scale
scale if you want
file2images(file,{
scale: 1.5 // all pages scale up to 1.5 size
})
options.pdfjsLib
I got problem when use pdfjs-dist
in next.js
, so I can use CDN version
<script src="some/cdn/pdf.min.js">
file2images(file,{
pdfjsLib: pdfjsLib // use cdn version
})
FAQs
convert pdf pages to images
The npm package browser-pdf-to-images receives a total of 1 weekly downloads. As such, browser-pdf-to-images popularity was classified as not popular.
We found that browser-pdf-to-images demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.