Skip to content

Instantly share code, notes, and snippets.

@Hachikoi-the-creator
Forked from nimone/Carousel.jsx
Last active February 8, 2024 09:07
Show Gist options
  • Save Hachikoi-the-creator/4d9ff83a2021fcb1596907d85be1eeb5 to your computer and use it in GitHub Desktop.
Save Hachikoi-the-creator/4d9ff83a2021fcb1596907d85be1eeb5 to your computer and use it in GitHub Desktop.
Build a carousel component like instagram purely in ReactJS, TS and TailwindCSS
import Carousel from "./Carousel";
import img1 from "path-to-local-image.jpg";
import img2 from "path-to-local-image.jpg";
import img3 from "path-to-local-image.jpg";
export default function ImageCarousel() {
const slides = [img1, img2, img3];
return (
<div className="relative">
<div className="max-w-lg">
<Carousel slides={slides} />
</div>
</div>
);
}
@chiucchi
Copy link

amazing, thank you!!

@SINAZZzz
Copy link

SINAZZzz commented Aug 2, 2023

Nice

@m-hari16
Copy link

its work and amazing, thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment