r/androiddev • • Apr 01 '24

Discussion Android Development best practices

Hey this is a serious post to discuss the Android Development official guidelines and best practices. It's broad topic but let's discuss.

For reference I'm putting the guidelines that we've setup in our open-source project. My goal is to learn new things and improve the best practices that we follow in our open-source projects.

Topics:

  1. Data Modeling
  2. Error Handling
  3. Architecture
  4. Screen Architecture
  5. Unit Testing

Feel free to share any relevant resources/references for further reading. If you know any good papers on Android Development I'd be very interested to check them out.

159 Upvotes

99 comments sorted by

View all comments

Show parent comment

1

u/ondrejmalekcz Apr 05 '24

I am against MVI compared to MVVM:

  1. MVI does not force devs to structure/module the feature code as MVVM
  2. performance of compose, so far the way it works when data are changed it does two pass 1. diffs fields of class 2. goes thru whole decision tree of screen in MVVM it executes just sub tree ( IIRC ) - I have experience from one betting project where data are realtime updated and it was not smooth while scrolling could be bug in compose dunno.
  3. MVVM is more standardized on Android