
Security News
/Research
Popular node-ipc npm Package Infected with Credential Stealer
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.
@tofandel/filepond-plugin-pdf-preview
Advanced tools
The PDF Preview plugin is an Extension of FilePond that will render a small preview when the uploaded file is of type PDF. It will use the browser native renderer.
Install using npm:
npm install @tofandel/filepond-plugin-pdf-preview
Or install using Yarn:
yarn add @tofandel/filepond-plugin-pdf-preview
Or using a CDN refernce:
https://unpkg.com/@tofandel/filepond-plugin-pdf-preview/dist/@tofandel/filepond-plugin-pdf-preview.min.js
Then import in your project:
import * as FilePond from "filepond";
import FilePondPluginPdfPreview from "@tofandel/filepond-plugin-pdf-preview";
Or reference it by CDN
<script src="https://unpkg.com/@tofandel/filepond-plugin-pdf-preview/dist/@tofandel/filepond-plugin-pdf-preview.min.js"></script>
Register the plugin:
FilePond.registerPlugin(FilePondPluginPdfPreview);
Create a new FilePond instance as normal.
const pond = FilePond.create({
name: "filepond",
});
// Add it to the DOM
document.body.appendChild(pond.element);
The preview will become active when uploading a PDF file.
If you want you can change the defaults for this plugin
in the javascript
pond.setOptions({
allowPdfPreview: true,
pdfPreviewHeight: 320,
pdfComponentExtraParams: 'toolbar=0&view=fit&page=1'
});
or in the html with the 'data-' atributes in the html tag
<input type="file"
data-pdf-preview-height="320"
data-pdf-component-extra-params="toolbar=0&navpanes=0&scrollbar=0&view=fitH"
/>
Be sure to include this lib's styles, by importing the minified css.
import "@tofandel/filepond-plugin-pdf-preview/dist/@tofandel/filepond-plugin-pdf-preview.min.css";
or by CDN
<link href="https://unpkg.com/@tofandel/filepond-plugin-pdf-preview/dist/@tofandel/filepond-plugin-pdf-preview.min.css" rel="stylesheet">
FAQs
Pdf preview Plugin for FilePond
We found that @tofandel/filepond-plugin-pdf-preview demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
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.

Security News
/Research
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.

Security News
TeamPCP and BreachForums are promoting a Shai-Hulud supply chain attack contest with a $1,000 prize for the biggest package compromise.

Security News
Packagist urges PHP projects to update Composer after a GitHub token format change exposed some GitHub Actions tokens in CI logs.