Hey Developers, today in this post, I will give you the 5 best tips to improve your development. In this post, we will discuss the top 5 things to avoid while developing android apps. If you already avoid this thing that well good, if you do not avoid this common mistake so try to avoid it, so without any further discussion let’s see the top 5 things to avoid while developing android apps.
Avoid these 5 Thing While Developing Android Apps
Avoid these 5 Thing While Developing Android Apps
1. Fragment Transaction
The replacement of Fragment transaction is Navigation Component. Navigation Component is a jetpack library that can manage navigation between the different screens in your app and its replaced manual fragment transactions completely.
2. Asyntask
Android Asyntask was the old way to handle background operation. It was deprecated in API level 30. Now, Kotlin coroutines are a fresh way to handle background operations.
3. Kotlin Synthetics
The Kotlin synthetics released in 2017 came Kotlin Synthetics. Kotlin synthetics use for creates an auto-generated class containing your view of every layout file and its replace calls to findViewById.
There are many cons in Kotlin synthetics like Partial null safety, only support Kotlin not support java, NullPointerException, and more, now it’s deprecated, so you can’t bind views using synthetics. The modern way to bind views is ViewBinding and DataBinding.
4. Shared Preferences
Shared Preferences were used to store and retrieve a small amount of data in local storage and the replacement of shared preferences of the Jetpack datastore preferences. Now you can use Jetpack datastore preferences for store and data instead of Shared preferences.
5. Dagger Android
Now hilt is the recommended library for dependency injection is android. The hilt is built on the top popular di library dagger. It is much easier to learn and implement.
Read More:
- 5 Best GitHub Repositories For Android Developer
- Android Working With Firebase – Signup And Login Auth.
- Getting Started With Firebase On Android.
- Android Interview Questions For Fresher 2021.
If you liked this article please share the post with your friends. I would love to hear your thoughts in the comment section. Thanks a lot!
Happy Learning!!!