Media preview Plugin for FilePond
npm install filepond-plugin-media-preview

The Media Preview plugin will kick in automatically when the uploaded file is of type video or audio and render a preview player inside the file item.

Install using npm:
``bash`
npm install filepond-plugin-media-preview
Then import in your project:
`js`
import * as FilePond from 'filepond';
import FilePondPluginMediaPreview from 'filepond-plugin-media-preview';
Register the plugin:
`js`
FilePond.registerPlugin(FilePondPluginMediaPreview);`
Create a new FilePond instance as normal.js
const pond = FilePond.create({
name: 'filepond'
});
// Add it to the DOM
document.body.appendChild(pond.element);
`
The preview will become active when uploading an video or audio file.
Both the video and audio preview can be enabled or disabled. Use the following options:
`js`
const pond = FilePond.create({
name: 'filepond',
allowVideoPreview: true, // default true
allowAudioPreview: true // default true
});
js
import 'filepond-plugin-media-preview/dist/filepond-plugin-media-preview.min.css';
``