Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pdfjs-viewer-element

Package Overview
Dependencies
Maintainers
1
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pdfjs-viewer-element - npm Package Compare versions

Comparing version 2.0.3 to 2.1.0

2

package.json
{
"name": "pdfjs-viewer-element",
"version": "2.0.3",
"version": "2.1.0",
"license": "MIT",

@@ -5,0 +5,0 @@ "author": {

# pdfjs-viewer-element
A web component for [PDF.js viewer](https://mozilla.github.io/pdf.js/web/viewer.html). See [demo](https://alekswebnet.github.io/pdfjs-viewer-element/index.html).
[![npm version](https://img.shields.io/npm/v/pdfjs-viewer-element?logo=npm&logoColor=fff)](https://www.npmjs.com/package/pdfjs-viewer-element)
[![Package Quality](https://packagequality.com/shield/pdfjs-viewer-element.svg)](https://packagequality.com/#?package=pdfjs-viewer-element)
⚠️ `pdfjs-viewer-element` uses PDF.js [prebuilt](https://github.com/mozilla/pdf.js/releases/download/v3.4.120/pdfjs-3.4.120-dist.zip), that includes the generic build of PDF.js and the viewer. To use the package you should **extract the prebuilt** files into some directory of your project. You may specify the path to this directory with `viewer-path` property (by default is '/pdfjs').
A web component for viewing pdf files in the browser. The package is based on [PDF.js viewer](https://mozilla.github.io/pdf.js/web/viewer.html) build and works with any framework. See [demo](https://alekswebnet.github.io/pdfjs-viewer-element/index.html).
⚠️ `pdfjs-viewer-element` uses PDF.js [prebuilt](http://mozilla.github.io/pdf.js/getting_started/), that includes the generic build of PDF.js and the viewer. To use the package you should download and **place the prebuilt** files to some directory of your project. You may specify the path to this directory with `viewer-path` property (`/pdfjs` by default).
## Install

@@ -24,3 +27,3 @@ ```

Extract the PDF.js prebuilt. See demo [example](https://github.com/alekswebnet/pdfjs-viewer-element/tree/master/public).
Place **PDF.js prebuilt** files to some directory of your project (`pdfjs` used as the standard name). See demo [example](https://github.com/alekswebnet/pdfjs-viewer-element/tree/master/public). You may call the directory as you want, but then you should specify the `viewer-path` property.

@@ -39,4 +42,8 @@ ```javascript

`viewer-path` - path to prebuilt directory (by default is '/pdfjs').
`viewer-path` - path to prebuilt directory (`/pdfjs` by default).
`locale` - language localization (e.g. 'en', 'en-US', 'es', 'de'), see [pdf.js i10n files](https://github.com/mozilla/pdf.js/tree/master/l10n) (the language of your browser by default)
## License
[MIT](http://opensource.org/licenses/MIT)
For this package - [MIT](http://opensource.org/licenses/MIT).
For the `pdf.js` library - https://github.com/mozilla/pdf.js/blob/master/LICENSE.
export declare class PdfjsViewerElement extends HTMLElement {
constructor();
static get observedAttributes(): string[];
connectedCallback(): void;
attributeChangedCallback(name: string): void;
updateIframe(): void;
constructor();
static get observedAttributes(): string[];
connectedCallback(): void;
attributeChangedCallback(name: string): void;
updateIframe(): void;
}
declare global {
interface Window {
PdfjsViewerElement: typeof PdfjsViewerElement;
}
interface Window {
PdfjsViewerElement: typeof PdfjsViewerElement;
}
}
export default PdfjsViewerElement;
SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc