Socket
Socket
Sign inDemoInstall

react-native-pdf-thumbnail

Package Overview
Dependencies
514
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    react-native-pdf-thumbnail

Generate thumbnail for PDF files


Version published
Maintainers
1
Install size
0.994 MB
Created

Readme

Source

react-native-pdf-thumbnail

A react native module for generating thumbnail for PDF files.

A wrapper for:

  • PDFKit on iOS (requires iOS 11+)
  • PdfRenderer on Android (requires API level 21 - LOLLIPOP)

No other JavaScript or native dependencies needed.

Installation

npm install react-native-pdf-thumbnail

Usage

import PdfThumbnail from "react-native-pdf-thumbnail";

// fileUri can use `file` scheme on iOS, `file` and `content` schemes on Android

const { uri, width, height } = await PdfThumbnail.generate(fileUri, 0);

The example app contains a document picker, it generates thumbnail for the selected PDF file. iOS example app Android example app

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT

Keywords

FAQs

Last updated on 06 Jul 2020

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc