- Carousels have so many types of UX
- Draggable
- Draggable with snapping
- Free slide
- Paginated
- Slidable with scroll wheel
The most basic carousel if probably with just a css overflow and snapping . But the moment you want “drag” functionality, this logic doesnt work and we need to work with transforming a div by “sliding” it along an x-axis. Once we do this we need to do all the hard work of figuring out the left-x position of every div slide. These become our slide points which can be used for writing our own snapping functionality and pagination
- this is a good demo that manages to keep native scroll functionality along with drag mechnanism - https://codepen.io/thenutz/pen/VwYeYEE