This post is solely to keep my learning progress. Nothing new, no innovation…
7th March 2021
My starting point is the google codelabs. I prefer to have an empty activity for my new projects and especially for something I learn it needs to be a step-by-step process. So thanks for the “Empty Compose Activity” but no.
I am directed to the documentation page for the Jetpack Compose. Of course, I scrolled down until I see some code. Added my configuration codes and saw a message at the right bottom of the screen.
This is not something I expected but it makes sense since ‘Compose’ is still in beta. The 4.2 Beta version is not enough either. I am installing the Canary version.
The installation is done. I’m looking for a way to close the “tips” window. Yes, trying to close it. (!) I know it is the canary version.
Force quit did the job. No tip is displayed the next time.
I created my GitHub repo and pushed the first commit.
I have created Theme.kt and Color.kt files in the ui package. It is a weird feeling since they are resources that can be used and accessed without the context object. Another topic is their usages. I’m sure people will go wild and standard is something we may not have for a long time.
- It is up to the developer to display the same composable on the preview with the one that will be used on the actual activity. A host composable would easily solve this problem though.
- It is required to “Build & Refresh” the preview every time and it takes around 10 seconds. (I guess this will be enhanced with the following android studio versions.)
- The design part is not displaying the whole screen but just the part that is defined. So what you see on the screen when you run the app is not previewed. (at least by default. maybe there is a way for that.)
At the end of the day, I haven't accomplished much but at least I have made some experiments on this new fancy tool. It will definitely change the android developers’ lives but it is far away from being stable mostly because of android studio.