Add a swipe menu to your Xamarin.Forms app

A common pattern in mobile apps is to use a swipe menu, a menu that appears when a user is swiping an item in a list for example. We often see this in mail- and messages apps.

For Xamairn.Forms ListView we had ContextActions. but they were pretty limited. But in the upcoming 4.4.0 release of Xamarin.Forms (now in public preview) a new control is introduced, SwipeView. SwipeView makes it possible to add a swipe menu to any other item. To do that, just wrap any item in a SwipeView. We can add swipe items in any direction, left, right, top, and bottom.


There are two different types of swipe behaviours/modes you can use for swipe, reveal and execute. Reveal shows options that the user has and to execute it, he/she needs to tap it. If mode is set to Execute, it will execute directly on swipe if the swipe gesture is long enough. To set the mode for swipe items we need to wrap the items in a SwipeItems element as below:



I have noticed that it is still some bugs in the control and we can also see that if we take a look at the issue list on GitHub, But I have started to use it anyway, because it was enought stable for my needs. If you found any bug or have feedback I know that the Xamarin.Forms teams is more than happy if you report it to them.

  12/9/2019 - 9:49 AM