
Security News
OWASP 2025 Top 10 Adds Software Supply Chain Failures, Ranked Top Community Concern
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.
react-image-video-viewer
Advanced tools
A React lightbox that supports videos, images and pinch zooming on images. Optimized for mobile UI with swiping, but can be used on desktop as well.
React Image Video Lightbox is a lightweight and customizable React component that provides a modern and responsive lightbox for displaying images and youtube or mp4 videos. It supports easy navigation, full-screen previews, and offers a seamless user experience for showcasing media content. This library is ideal for galleries, portfolios, and any project requiring media presentation with minimal effort. Compatible with modern React versions and fully responsive across devices.
npm install react-image-video-viewer
<ReactImageVideoviewer
data={[
{
url: "https://upload.wikimedia.org/wikipedia/commons/thumb/f/fe/Flag_of_Uruguay.svg/800px-Flag_of_Uruguay.svg.png",
type: "photo",
altTag: "some image",
},
{
url: "https://www.sample-videos.com/video321/mp4/240/big_buck_bunny_240p_1mb.mp4",
type: "video",
title: "Placeholder video",
},
{
url: "https://www.youtube.com/embed/iTjxqWolgHY",
type: "video",
title: "some other video",
},
]}
startIndex={0}
showResourceCount={true}
onCloseCallback={this.callbackFunction}
onNavigationCallback={(currentIndex) =>
console.log(`Current index: ${currentIndex}`)
}
/>
| Property | Type | Description |
|---|---|---|
| data | Array of resources | An array of resource objects (see resource object below) |
| startIndex | number | Index of image/video where the viewer should open |
| showResourceCount | boolean | Show resource count in the upper left corner |
| onCloseCallback | Function => void | Callback function called when the viewer is closed |
| onNavigationCallback | Function(currentIndex) => void | Callback function called on navigation between resources |
| Property | Type | Description |
|---|---|---|
| url | string | Url of the image/video |
| type | string | Two types are supported - 'photo' & 'video' (only .mp4, .mov and YouTube videos are supported) |
| altTag | string | Alt tag for image |
| title | string | Title for iframe when rendering YouTube, .mp4 or .mov video |
| poster | string | Poster image for .mp4 or .mov video |
| autoPlay | boolean | Autoplay video for .mp4 or .mov video |
FAQs
A React lightbox that supports videos, images and pinch zooming on images. Optimized for mobile UI with swiping, but can be used on desktop as well.
The npm package react-image-video-viewer receives a total of 112 weekly downloads. As such, react-image-video-viewer popularity was classified as not popular.
We found that react-image-video-viewer demonstrated a healthy version release cadence and project activity because the last version was released less than 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
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.