react-multiple-image-post-view3
Version:
The react-multi-image-post npm package is a versatile solution for developers seeking to integrate multi-image posting or gallery functionality seamlessly into their React application.Whether you're building a social media plateform,an e-commerce site, or
51 lines (48 loc) • 1.53 kB
JavaScript
import MultiImagePost from "../src";
import { createRoot } from "react-dom";
const images = [
{
media:
"https://wallpapers.com/images/hd/hd-path-between-red-trees-xhpeo2g5g0afjcgh.jpg",
type: "image",
},
{
media:
"https://dharmapublication.com/wp-content/uploads/2023/08/Firefly-A-Beautiful-Island-at-the-middle-of-the-ocean-surrounding-a-huge-jungle-at-night-moon-hd-3.jpg",
type: "image",
},
{
media:
"https://letsenhance.io/static/8f5e523ee6b2479e26ecc91b9c25261e/1015f/MainAfter.jpg",
type: "image",
},
{
media:
"https://img.freepik.com/free-photo/majestic-mountain-peak-tranquil-winter-landscape-generated-by-ai_188544-15662.jpg?size=626&ext=jpg&ga=GA1.1.1700460183.1712188800&semt=ais",
type: "image",
},
{
media:
"https://c4.wallpaperflare.com/wallpaper/297/22/531/lake-blue-moonlight-moon-wallpaper-preview.jpg",
type: "image",
},
{
media:
"https://www.befunky.com/images/prismic/1f427434-7ca0-46b2-b5d1-7d31843859b6_funky-focus-red-flower-field-after.jpeg?auto=avif,webp&format=jpg&width=863",
type: "image",
},
{
media:
"https://t4.ftcdn.net/jpg/05/40/82/11/360_F_540821167_aAv3kKYIaUpb3Gkd4ib3Qt61OFcMWuT8.jpg",
type: "image",
},
];
const ReactMultiPost = () => {
return (
<div>
<MultiImagePost images={images} />
</div>
);
};
const root = createRoot(document.getElementById("reactMultiPost"));
root.render(<ReactMultiPost />);