ListView is one of my favourite UI controls available in Xamarin.Forms. It is mostly easy to use and customise. Just bind a collection of data, define the representation of each item and you are done!
However, there is one pitfall which most of the developers tend to ignore – if the bound collection is empty, the
ListView will have nothing to show. Depending on the targeting platform it may look ugly or confusing for the end user.
In this blogpost we will check few possible solutions. One solution will be purely implemented on the
ViewModel level and the other one will be a reusable
ListView control wrapper.