npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

pdf-pages-to-base64-images

v1.0.1

Published

This package use for parse PDF pages (content) to base64 (image)

Downloads

57

Readme

PDF PAGES TO BASE64 (IMAGES)

If you want to install only package

npm i pdf-pages-to-base64-images --save

You will make the add-ons yourself, you can download the repository.

https://github.com/Rashad-Yusifov/pdf-pages-to-base64-images

How to use ? (example)

    import PdfPagesToBase64Image from 'pdf-pages-to-base64-images'; 

    // you must first call this command

    PdfPagesToBase64Image.initDependency();

    // let's keep it up (options) | if you want see more options, please check bottomest of the page


    const options = {
        quality: 1.0,   // 0.1 - 1.0 this range is quality of base64's images
        pdf: 'https://www.YOURSITE.com/your.pdf',   
        getCanvas: false, // when you change it true, you will get canvas tag
        getUrl: true // it's for base64 (images) if you don't need it, you can be false it
    };

    


    // let's keep it up (use)


    PdfPagesToBase64Image.createPages(options).then(res => {
       console.log(res) 
    }).catch(err => {
      console.log(err)
    });



     // And also you can get total Pdf pages count
   
     let totalPage = PdfPagesToBase64Image.totalPage; 

When you have success output it will like that

   {
        code: 200,
        message: "SUCCESS",
        data: [
            {
                base64: (...),
                canvas: (element) // if you did select canvas: true
            }
        ]
    }   

When you have error output it will like that

   {
        code: 400,
        message: "ERROR",
    }   

Thank you so much for downloading.

    if it worked for you, you might add Star.
    that's all.