0
Hello, I had to create a few times recyclerview
which had the same principle as expandablelistview
for that, I have always made use of this lib
It solves the problem. But this is a good solution?
0
Hello, I had to create a few times recyclerview
which had the same principle as expandablelistview
for that, I have always made use of this lib
It solves the problem. But this is a good solution?
2
Yes, if it solves your problem and is easy to use and implement, it is a good solution, since today we do not have it in RecyclerView
.
In my projects I have, at times I needed to do this, but I chose to do it manually without using the library, because depending on what you will use, it is relatively easy to do.
For example, I have a project here used for restaurants, where you have a list of products and each product on the list has its price list. To implement this I put only one RecyclerView
with a Adapter
and within this Adapter
in the onBindViewHolder
I put to create the Adapter
from the price list. In my product layout, I have a new RecyclerView
for price list, so prices are loaded within each product. When the user clicks on a product, I change the display of the price list that is on it to visible, functioning as an expandable list.
All this would be easily implemented using this library, but to avoid too many dependencies, and as it is simple for my case, I decided in that way.
Browser other questions tagged android
You are not signed in. Login or sign up in order to post.