Vikas Jilla
Vikas Jilla

Reputation: 217

My screen contains large set of identical views should I add them staticlly or dynamically?

I want to design a screen which contains some ten identical components(each component contains textview and imageview).What's the better way to design it? Should I add them directly to xml or by looping dynamically.

Upvotes: 0

Views: 32

Answers (1)

seema
seema

Reputation: 991

Since it contains collection of similar data, use recycler view and add views dynamically using adapter.Refer this to know more about using recycler view Via recycler view, views can be reused, thus it manages memory.

Upvotes: 1

Related Questions