Build a carousel with next/prev arrows, dots, infinite looping, autoplay (pause on hover), and touch swipe.
Skip to solutionKEEP THE
mediumFrontend
Build an Image Carousel with Infinite Loop & Swipe
768 views
01
Understand the problem
ReactCarouselAnimationGestures
02
Attempt it yourself
Sketch your approach before reading the solution — that's what interviews test.
Nudge consolestandby
Stuck? Beam a request up — the console returns a conceptual nudge that guides your logic without spoiling the implementation.
03
Study the solution
Requirements
- Show one slide at a time (or 1.2 peeking); arrows wrap infinitely (0 → last, last → 0) with smooth translate.
- Dots indicate active slide; click to jump. Autoplay every 3s, pause on hover/focus and when tab hidden.
- Touch swipe: drag threshold 40px to advance; spring animation.
- Keyboard ←/→, `ari
Solution ready — 2 min read
Classified // press E to declassify
04
Join the discussion
Discussion (0)
Sign in to join the discussion.
No responses yet. Be the first to share what you think.
Transmission complete // awaiting log
KEEP THE
STREAK ALIVE.
Dossier 33 of 87 decoded in the Frontend Machine Coding track. One more won't hurt.