Understanding Compose (Android Dev Summit '19)

preview_player
Показать описание
This session covers the benefits of a declarative reactive UI system like Jetpack Compose and how it applies to real problems that Android developers have today. Additionally, this talk expands on the programming model of Jetpack Compose and some of its implementation details the can help you understand how Compose works.

Presented by: Leland Richardson‎

#AndroidDevSummit #jetpackcompose event: Android Dev Summit 2019; re_ty: Publish; product: Android - Jetpack Compose; fullname: Leland Richardson;
Рекомендации по теме
Комментарии
Автор

Google is trying to migrate layout XMLs to be like Flutter?

moshewaisberg
Автор

So it's basically like React Components now, which is a good thing!

BasantSiingh
Автор

Google io 2021 we are introducing redux-compose and redux-coroutines for communication between different layers

alexneeky
Автор

20:20 this is why you learn algorithms when interviewing for FAANG

ikeo
Автор

Really awesome video, I can't wait to see how Compose progresses. Playing around with it during the conference was very promising though. I think after I get through the rest of my Modern Android Development video series I'll start creating one for future looking things (such as Compose) 😁

CodyEngelCodes
Автор

Notes for myself
- Declarative vs Imperative: 8:40
- Composition: 11:00
- What @composable actually does? 18:19

santoshpillai
Автор

@9:20 When declaring Declarative vs Imperative, there is a minor bug in the imperative code (if no paper, remove paper). But, more importantly, the declarative code doesn't even handle the edge case of displaying the text "99+". It wouldn't add much complexity to cover that edge case in the declarative code (Badge(text=if(fire) "99+" else "$count") but it feels dishonest to ignore it and benefit from the code looking "cleaner".

Condog
Автор

If I understand this properly, it's able to memorize states of your UI and change views only if the state changes. Seems powerful, but the usage is still confusing.
First, I didn't get what the '+' operator means.
Next, it was told that "a composable function can be called from only within a composable function", so, how can one use this with libraries like, for example, RxJava?
In the presentation there is a call to getData() function (25:42), which either returns the prepared data or returns null, if the data is not ready yet. And thus, there must be a way to re-call the composable App function when the data is ready. How is this handled? Does the module which provides the data call the UI module's App function? - But that's a total snafu because it's typically the UI which calls the data module's methods.
So, after watching 2 videos from Google IO's about composable UI I'm left with a huge misunderstanding.

НектоЛохматый
Автор

I didn't understand yet what the "+" before the "hooks" mean.

danieldaschle
Автор

im lost since minute 16, the recomposition. Compose is simply an implementation of React.js's Component. Why not use the same name, it is good for developer :D

maxchin
Автор

Very helpful video, compose makes much more sense after understanding this.

praveenp
Автор

Does this mean that we will go away from context and reference of the activity to the views ?

arvindrangarajan
Автор

For me is total no-sense, I think they will provide this as an external library to integrate in projects but we still be able to use XML layouts, then this approach for me has so much lacks. For example how this approach would works if I want to build a custom animated drawable?

Then, how to extend a Button() to make a custom view? Then how to see layout changes in real time while creating the view inside the editor itself? It should let me see a preview of what the final result is

I will prefer XML so far, it is much clear then with dataBinding it is the top of the top

OresteAcacia
Автор

awesome share for go deep into ui development construct.

abnerwilliams
Автор

I think at 9:38 Last second if statement is wrong

siddharthareddy
Автор

Betting on Kotlin takes its toll. Requiring changes to a compiler for such things is ridiculous. But as the CTO of Jetbrains often reiterates, he doesn't see use cases for compile time functions (aka real macros). Well this here is one of 'em.

iphonebonn
Автор

So it's react and that's cool.

jibraniqbal
Автор

Can anyone tell me that how can I improve my coding skill without any cost?...
. please

yishubaghel
Автор

So, if you make Kotlin like Flutter, then why shouldn't I use Flutter in the first place?

Apenschi
Автор

9:26 and 9:46 are terrible examples. The non-compose code at 9:26 is intentionally written badly. You could write it in a very similar manner to the compose example. And the compose example is terrible because it's the opposite of separating concerns. The first 5 minutes is talk about separating concerns and then you give an example with business logic and ui mixed together.

Majora