RecyclerView data shows duplicate problems. (Solutions such as ListView are similar)
After searching on the Internet for a long time, I found that the modification methods are too troublesome, and some of them are relatively copycats. I think there should be a very simple modification method for this problem, so after various searches, I finally found a more serious and simple modification method:
just overwrite the following method in the Adapter:
@Override public long getItemId(int position) { return position; } @Override public int getItemViewType(int position) { return position; }