touch-action

The CSS property that tells the browser in advance which touch gestures it should handle itself, such as vertical panning, and which to leave to your code.

In more detail

touch-action: pan-y keeps native vertical scrolling while giving horizontal swipes to a carousel, and none gives every gesture to a drawing canvas. Because it is declared in CSS, the browser knows before any JavaScript runs and adds no delay.

Related terms

Taught in

References