React Hook to create and revoke URL for any instance of `File`, `Blob` or `MediaSource`.
npm install use-object-url



React Hook that receives an instance of File, Blob or MediaSource and creates an URL representing it. It releases URL when component unmount or parameter changes.
``js
import useObjectURL from 'use-object-url';
const DownloadFileLink = ({ file, filename }) => {
const fileURL = useObjectURL(file);
return (
Download
);
};
`
This library is published in the NPM registry and can be installed using any compatible package manager.
`sh
npm install use-object-url --save
$3
This module has an UMD bundle available through JSDelivr and Unpkg CDNs.
`html
``Documentation generated from source files by Typedoc.
Released under MIT License.