I created Xamarin bindings library for the groupie library. So, I introduce it in this article.
Xamarin bindings library for the groupie library. Contribute to CORDEA/GroupieXamarin development by creating an…
Groupie library is here.
Groupie helps you display and manage complex RecyclerView layouts. - lisawray/groupie
Groupie is awesome library to handle complex RecyclerView layouts easily. I often use this library when creating RecyclerView layouts with android apps using Java/Kotlin.
Currently, GroupieXamarin is supports only groupie 2.1.0 because groupie 2.2.0 or later has been migrated to AndroidX but task to migrate Xamarin.Android bindings to AndroidX seems to be in progress. (I am watching the AndroidSupportComponents AndroidX branch.)
I tried with the groupie’s latest library, but not going well because package name is different between groupie and Xamarin.Android.Support.v7.RecyclerView. If you know how to bind, please let me know :)
You can install using nuget.
You can use in the same way as original groupie.
For example, define item…
class ListItem : Item
private readonly string _title;
public ListItem(string title)
_title = title;
public override void Bind(Object holder, int position)
var viewHolder = (ViewHolder) holder;
var title = viewHolder.Root.FindViewById<TextView>(Resource.Id.title);
title.Text = _title;
public override int Layout => Resource.Layout.list_item;
and add to GroupAdapter.
var adapter = new GroupAdapter();
var recyclerView = FindViewById<RecyclerView>(Resource.Id.recycler_view);
You can find other examples from the following.