Transcript from the "Wrapping Up" Lesson
>> So, today we go over a lot. Okay, so think about what's your knowledge when we started and what's your knowledge now? So you will learn Kotlin, how Kotlin looks like and work, jetpack composable, you know everything is a function, and it's composable function on a preview. We've seen modifiers and how we use a syntax from Kotlin that looks weird the first time you see that, but is like naming the arguments.
[00:00:37] But it is actually pretty useful for jetpack compose naming the arguments. Because if not, you don't know what argument you're actually setting, okay? We've seen how to work with a state management, we've seen a state hosting. A state health is when you have composable that receives a state from the outer element, the our composable, and also it sends back changes to that element.
[00:01:05] So in this case, the state, we use that in different places. We use the data manager with view model, so it's a little bit about how view model works. And downloaded Json automagically because we've never parsed the data or do anything with the Json. We just created an array of categories and magically it worked, okay?
[00:01:30] It actually downloaded the data, consumed the web service, and converted that into our model. Have in mind, that's not part of Android, we injected a couple of libraries to do that, okay? Do we have any final question?
>> I mean, it's just completed some before we'll be talking about like, no, just is there is the, I mean, we do all this state management through going through Android things, right?
[00:02:03] Is there a way to create your own class and just have like a, we'll be able to manually tell it, okay, we have a changes, is there a way to do that?
>> Let me see if I understand the question. So there is, let me go back to one slide when we weren't telling everything that we have here.
[00:02:21] So there are a couple of things that we haven't covered today in our example, one is composition local. Composition local lets you in check through the composition, remember what's the composition, the hierarchy. So we can check through the composition elements that anyone in the composition can use, without actually passing the objects by arguments one by one.
[00:02:45] So right now, we have our data manager at the app level, and we are passing that to the and then maybe the is passing down to another one, one by one. Instead of doing that, when you have a really big composition like a large hierarchy, you can use composition local to some time in check something that goes automatically through.
[00:03:06] And we can use a data manager is one example to do that. And there are many other design patterns that you can use, MBBM, pipe, there are many design patterns, architectural design, patterns that you can apply. Once you understand the basics, then you decide, okay, how can we going to organize this?
[00:03:25] And also there are more mutable states, so not just mutable states. There are many other ways to actually create a state and then you detect when something changes, so you update composable, okay?
>> I was wondering if there's, I mean this was just a simple array. But well, is there just wait, okay, we checked with changing the data, like we changed it instead of just keeping, modifying it to just be able to,
>> I mean the whole idea of using state patterns is that you will always stay with basic data. So most of the time it's going to be just an array. Even if you have a very complex data model, at the end, you will listen for basic data, okay?
[00:04:08] Because if not you will have probably, how do you detect that someone has something, [CROSSTALK]
>> I wasn't trying to detect, I was just thinking that there's a, mike a hook dock and, okay, there's a weight, there's a [CROSSTALK]
>> I mean, there are many ways in many patterns, yeah.
[00:04:22] And you can do it without the pattern, and you can just mess with the whole structure and the wherever you want at some point. But what you do have are design patterns, okay? Architectural design patterns, and there are a couple. Also jetpack compose, within Android It's kind of new.
[00:04:38] So it's still new, okay? In fact, it became stable, okay? Immediately before the pandemic. So, there are still work to do, in terms of setting design patterns. There are alot of design patterns that are actually coming from other libraries and other ideas including react. But there's still work to do on that side, okay?
[00:05:03] So jetpack compose is still new, they're not so many companies apart from Google, using it in production. Or they start a new app today and they say let's go directly with jetpack compose, they're testing with some screens, with some parts of the app, okay? [INAUDIBLE] A new framework.
[00:05:19] But actually, it's the only framework that we can actually teach in a day. Because to get the same experience, the same app with the classic XML, we need at least three days, atleast. So its actually good news that we have a modern framework that I can lead up to this in one day.
[00:05:39] Well, I hope that now you understand a little bit about Kotlin. We will check back compose and how to create an app on Android how to test the app how to use the emulator, briefly, of course that much more to cover. It's a really a large ecosystem, but at least that you have like, all the important parts to just start growing your experience and your app.
[00:06:01] So, if you publish any app in the Play Store let me know. Send me the link, and I will try it, okay? So, thank you and see you next time.