`Day 58` - Continue building Note App for <https:/...
# 100daysofkotlin-2021
b
Day 58
• Continue building Note App for course ◦ Hilt setup ◦ Navigation between fragments implemented ◦ Viewmodels for fragments created ◦ Resource class & Event Wrapper class created ◦ Create class to check for Internet Connection (used different methods for version >= android marshmallow ◦ Register Users implemented. Creating an account sends info to Ktor server & saves to MongoDb
Self-Comment
• Set up Hilt in project. It was nice to build more than just a local database inside of the AppModule. Good practice with NoteApi for Retrofit & first time encrypting shared preferences. Looking forward to adopting these in Daily Doc later on. I have a feeling that my previous version of Daily Doc is going to be completely revamped after this. (A good thing) 😅 • I definitely need to practice implementing the Resource class & Event Wrapper class in project(s). Easy to understand and valuable, but also easy to overlook when building a project • I may opt out of FirebaseAuth on Daily Doc and implement a simpler login method people can use. It took quite awhile to implement, but I was struggling to create more advanced features in doing so. I may just use a simple / secure login method instead to have full control over it. Will decide after this course! ------------------------------------------------------
Day 59
• Continue building Note App for course ◦ Implemented ability to Login a user in app (only implemented Registry day prior) ◦ Keep user credentials stored in SharedPreferences until logged out. To keep user logged in the event of no internet connection ◦ Implement caching ◦ Display / Add / Update Notes
Self-Comment
• Big sections covered, but nothing too particular to mention besides caching. I hadn't used shared preferences before, but I vaguely recall that DataStore is often used instead. I should look into this • Caching - 1: Fetch notes from server, 2: cache into local database, 3: Display in RecyclerView. This networkBoundResource file is an eye opener for sure! • After taking all that time off and slowing down my progress it feels like I've gotten rusty (couple of weeks). Some of the material covered feels like it's going over my head. I should finish up the course tomorrow or at the latest Tuesday. Then I'll work on reimplementing what was covered in either Daily Doc or another simple project to help instill the material.