Skip to content
pubscout

swipe

0.0.1, released 5 years ago by an unverified publisher

Detect swipe gestures in all four directions in Flutter.

WASM-ready
$ flutter pub add swipe
Source repository

What it does

Provides a Swipe widget to easily detect swipe up, down, left, and right gestures on its child widget. Supports customization parameters such as thresholds, displacement, and velocity for both vertical and horizontal swipes.

AI-written summary of version 0.0.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to detect directional swipe gestures on a widget.
  • You want custom thresholds or velocities for swipe detection.

Skip it when

  • You only need standard tap or pan gestures covered by Flutter's built-in GestureDetector.
  • You need complex gesture recognition beyond simple four-way swipes.

Strengths

  • Simple and straightforward API.
  • Customizable vertical and horizontal thresholds, displacement, and velocity.

Weaknesses

  • Limited to basic four-way swipe detection.
  • Early version (0.0.1).

Setup

Kind
Flutter widgets
Effort
Low
Code generation
No
Direct dependencies
0
Swipe(
  child: ..., // your child widget
  onSwipeUp: () {
    // do something when swiping up
  },
  onSwipeDown: () {
    // do something when swiping down
  },
  onSwipeLeft: () {
    // do something when swiping left
  },
  onSwipeRight: () {
    // do something when swiping right
  },
)

Alternatives

Packages that do the same job and could replace swipe.