Socket
Socket
Sign inDemoInstall

svelte-pdfjs

Package Overview
Dependencies
86
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    svelte-pdfjs

A wrapper around Mozilla's PDFJS renderer. Only cares about loading and showing the PDF and nothing else, all the fancy stuff such as styling the viewer is left up to the consumer. Still in early stages so feel free to create an issue or a PR for any bugs


Version published
Weekly downloads
9
decreased by-95.34%
Maintainers
1
Install size
17.0 kB
Created
Weekly downloads
 

Changelog

Source

0.4.0-rc.0

Minor Changes

  • [breaking] make pdfjs-dist a peer dep

Readme

Source

svelte-pdfjs

A wrapper around Mozilla's PDFJS renderer. Only cares about loading and showing the PDF and nothing else, all the fancy stuff such as styling the viewer is left up to the consumer. Still in early stages so feel free to create an issue or a PR for any bugs that you find, any improvements or feature requests.

Usage

See src/routes/index.svelte
Demo

SvelteKit

It's compatible with SvelteKit, just import the component and use it in a {#if browser} you'll have to install pdfjs-dist as a dependency.

TODOs:

  • Text layer rendering
  • SvelteKit compatibility
  • Think of a better name for the zoomLevel prop on Page
  • SVG renderer
  • Annotation layer
  • Error handling
  • Expose more stuff

License

MIT

Keywords

FAQs

Last updated on 01 Oct 2022

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