The basic mechanism is one track of slides laid side by side, moved with `transform: translateX(-index * 100%)`. While dragging, add the raw finger movement directly for instant response; on release, use the distance and velocity to decide whether to advance, go back, or spring to rest.
The dot indicator isn't decoration — it's progress information, "slide N of total." Widening the dot for the current slide lets someone infer position even without a screen reader. Swapping the button label from "Next" to "Get Started" only on the final slide is an explicit signal that this is the end.
Onboarding isn't a mandatory gate to sit through every time — keep a "Skip" visible in a corner so anyone can leave whenever, and avoid mixing it with screens that collect input, like sign-up. There's also research suggesting feature explanations stick better as coach marks shown the first time someone actually meets that screen, rather than crammed into an intro carousel.
When to use
Use it on first launch to convey the app's core value in three slides or fewer. If there is a lot to explain, splitting it into in-app coach marks beats stretching the carousel longer.