/Instant-PDF-Reader

This project is an Instant PDF Reader πŸ“–πŸ€“ web app using HTML, CSS, and JavaScript. It enables users to upload PDFs and view them instantly in the browser, featuring dynamic rendering and responsive scaling for a seamless reading experience.

Primary LanguageJavaScriptApache License 2.0Apache-2.0

Instant-PDF-Reader

This project is an Instant PDF Reader πŸ“–πŸ€“ web app using HTML, CSS, and JavaScript. It enables users to upload PDFs and view them instantly in the browser, featuring dynamic rendering and responsive scaling for a seamless reading experience.

For live demo πŸŽ‚Click to visit website ➑️ https://akshayadeveloper.github.io/Instant-PDF-Reader/index.html For video▢️ tutorial 🎦 click here ➑️πŸ₯ž https://www.youtube.com/@AkshayaDeveloper.

Mobile πŸ“± Version Demo

Desktop πŸ–₯️ Version Demo

Project Description:

This is an Instant PDF Reader web application built using HTML, CSS, and JavaScript. It allows users to upload PDF files and view them instantly within the browser.

Uses:

  • Viewing PDF files instantly within the browser without the need for additional software.
  • Providing a user-friendly interface for reading PDF documents.

Features:

  • Upload PDF files using a file input element.
  • Dynamically render PDF pages onto the canvas element.
  • Adjust the scale of the PDF pages based on the viewport size.
  • Support for handling window resize events to update the scale accordingly.

Libraries/Frameworks:

  • pdf.js: Used to render PDF documents in the browser.
  • HTML, CSS: For the structure and styling of the web application.
  • JavaScript: For handling user interactions and dynamically rendering PDF pages.

Functions:

  1. renderPDF(data): Renders the PDF document onto the canvas element.
  2. calculateScale(page): Calculates the appropriate scale for rendering based on the viewport size.
  3. Event listeners to handle file upload and window resize events.

Special Features:

  • Dynamically adjusts the scale of PDF pages to fit the viewport size, providing a responsive viewing experience.
  • Utilizes canvas element for rendering PDF pages, enabling smooth and efficient viewing directly within the browser.

Beneficiaries:

  • Users: Individuals who need to quickly view PDF documents without installing additional software.
  • Developers: Developers can customize and extend the functionality of this PDF reader for specific use cases or integrate it into larger applications.

How it Benefits:

  • Provides convenience by eliminating the need for external PDF viewers.
  • Offers a lightweight and efficient solution for viewing PDF documents online.
  • Enhances accessibility by allowing users to view PDFs on various devices without compatibility issues.