digidem / comapeo-mobile

The next version of Mapeo mobile
GNU General Public License v3.0
5 stars 0 forks source link

feat: List tracks in observations list #408

Closed ErikSin closed 1 month ago

ErikSin commented 1 month ago

Adds recorded tracks to observations list. Clicking on the track will not do anything, that is being handled in a follow up PR

image
ErikSin commented 1 month ago

i think using memo like this is similar to adding every prop to a dependency array (i.e. checking each one as they change), so there's technically more overhead in this case. but yeah, agree that it's probably not a huge issue in this case

Just to clarify. I more so meant that there is no overhead for developers. My main reasoning for not memoizing everything in a react function is because it becomes hard to maintain as complexity increases. Dependency arrays become long, and the code just becomes quite difficult to read. That doesn't really apply to React.memo as all of that is internally kept track off, so I generally don't feel the need to not use it.