Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there another solutions instead of nested Recyclerview

Now my code is about Nested RecyclerView for 3 layer example

  • RecyclerView of Product have
  • RecyclerView of comment and order inside and both also have
  • RecyclerView of reply|COMMENT in comment and order too.

The customer wants this.

Is there another solutions to handle this with good performance.

While I'm using Nested RecyclerView it lags and slow if a lot of product, comment, order and reply to display

like image 795
s. srichomthong Avatar asked Jan 26 '26 08:01

s. srichomthong


1 Answers

Nested Recyclerviews are a bad practice in the material design or google app design guidelines. You will have trouble with a bad and wrong scroll behaviour, it is simply not possible to work with this fluently as a user. Also your views will not be recycled and if your content grows the app will act very slow! There are workarounds but it is all a bad practice and more a bad design. You should inform your customers because there are not aware of those design failures and the technical bottlenecks.

A better way would be to enable to collapse the nested views. And just scroll the whole view or to use paging inside all nested views.

like image 77
Erythrozyt Avatar answered Jan 27 '26 23:01

Erythrozyt