Skip to content

scroll-snap-type

Utilities for configuring scroll snapping axes and strictness on a scroll container.

InteractivityTailwind v4 Spec
ISS preview
Iced + ISS preview demonstrating scroll-snap-type
ISS preview for scroll-snap-type
use iss::{scroll_box_tw, tw};
let strip = scroll_box_tw(cards, tw!("w-full overflow-x-auto snap-x snap-mandatory scroll-px-4"));
Tailwind Class CSS Property / Effect iss::typed Builder
snap-none scroll-snap-type: none; .snap_none()
snap-x / snap-y / snap-both Snap axis; .snap_x() / .snap_y() / .snap_both()
snap-mandatory Strict snapping to nearest target; .snap_mandatory()
snap-proximity Proximity snapping (default); .snap_proximity()

scroll-snap-align · scroll-snap-stop · scroll-padding