Lazy layouts in Compose

  Рет қаралды 98,598

Android Developers

Android Developers

Күн бұрын

Пікірлер
@krisztianbotos168
@krisztianbotos168 Жыл бұрын
Amazing training series on Jetpack Compose. You guys are crushing it! It's a pleasure to learn from you.
@codingwithmitch
@codingwithmitch 2 жыл бұрын
Great tip about default height
@AndroidDevelopers
@AndroidDevelopers 2 жыл бұрын
We're happy to hear the tutorial was helpful! Be sure to check out the links in the description for even more tips and tutorials 😎
@ArtyomIvanyuk
@ArtyomIvanyuk 2 жыл бұрын
Great video! Presenters (especially the one in a dark shirt) clearly explain the concepts, thanks!
@ВиталийСорокин-с2с
@ВиталийСорокин-с2с 2 жыл бұрын
русский хвалит русского, неудивительно
@gmk57
@gmk57 2 жыл бұрын
They are all in the dark shirts ;)
@codingwithmitch
@codingwithmitch 2 жыл бұрын
Incase this ends up helping someone... We were animating visibility of a collapsible section in our lazy list by setting the "invisible" items to 0px height and this was causing a lot of latency.
@clementjoymasinamela4244
@clementjoymasinamela4244 2 жыл бұрын
You need to come back Mitch, we miss your awesome content.
@farazahmed7
@farazahmed7 2 жыл бұрын
yo Mitch wadduppp
@theren8311
@theren8311 Жыл бұрын
If it's collapsible, why animate its measurement manually? Just use the AnimatedVisibility(Boolean) block around your composable, or take a look at the Animations docs to see how to handle performance, if it is the built in function really isn't suitable for your use case. My guess is you're skipping steps that makes it performant, and AnimatedVisibility would handle it. Just keep in mind that each an every step of the animation (every pixel you reduce by) triggers a recomposition of the specific composable, and every single change to the specific composable triggers a recomposition of the Lazy list. Also don't measure performance in a non release build (if you are). I've been collapsing cards in lists since Compose was beta, and I've never experience any jank, so just revise those manual implementations.
@theren8311
@theren8311 Жыл бұрын
Also 13:14
@ivanvlasov8308
@ivanvlasov8308 2 жыл бұрын
Thanks, very helpful! I also like how you invite speakers of different nationalities in one video, this earns respect
@StevdzaSan
@StevdzaSan 2 жыл бұрын
Quite informative video filled with such a great presentation resources. Thanks guys!❤
@AndroidDevelopers
@AndroidDevelopers 2 жыл бұрын
We appreciate the kind words, Stevdza-San! You can also check out our guide on Custom layouts for Jetpack Compose: goo.gle/3CDQzzX and an amazing video with more helpful tips and tricks regarding Layouts: goo.gle/3fCcher Happy learning ❤️
@En_Diel
@En_Diel 10 ай бұрын
These are very helpful, keep them coming
@abdonasr1222
@abdonasr1222 2 жыл бұрын
Wow!! so valueable performance tips
@appsbeyond
@appsbeyond 2 жыл бұрын
Awesome video. Was hoping to get a hint of how to provide a background around a "section" of items since it is advised not to next two scrollables that scroll in the same direction.
@DarkoLuketic
@DarkoLuketic Жыл бұрын
Lepotica, steta da sam pre star za nju :)
@TashingaPemhiwa
@TashingaPemhiwa 2 жыл бұрын
Great video on working with lists in Compose. How does one achieve prefetching?
@AndroidDevelopers
@AndroidDevelopers 2 жыл бұрын
Hi Tashinga! Here's a link that might help you on your quest to learn more about prefetching: goo.gle/3ur5xof 😀
@mill107
@mill107 3 ай бұрын
I'm not sure I fully understand on the topic regarding 'Multiple elements in one Item', anyone know where can i find documentation or more info? thanks in advance.
@nesyou4342
@nesyou4342 2 жыл бұрын
Greet! but there's no documentation to how to implement custom LazyLayout
@andreykulikov1844
@andreykulikov1844 2 жыл бұрын
Yes, we in fact intentionally didn't show it as the api is in its early stages and can change a lot. We didn't want this video to became outdated because of that. LazyLayout is not yet production ready, but I hope that the public documentation and the ability to read the sources of our components will allow the early adopters to try it out
@gilbertsenyonjo963
@gilbertsenyonjo963 2 жыл бұрын
Dont mean to be rude, but I wonder if its just me who doesnt enjoy watching many people present in the same video/tutorial.
@gameofcodes9832
@gameofcodes9832 2 жыл бұрын
In 16:15 let's say I want to have some modifiers for items block (not in while LazyColumn) how can I do so?
@Musa-al-Khwarazmi
@Musa-al-Khwarazmi 2 жыл бұрын
I hope some day we get hard working layouts.
@luisdavidorellana
@luisdavidorellana 2 жыл бұрын
Gran video, información valiosa! Muchas gracias por los tips que nos dan 💚
@joesilva-rodriguez9
@joesilva-rodriguez9 2 жыл бұрын
That moment when you don't have a scroll bar and your PO wants a scroll bar. Bad...
@coldwised
@coldwised Жыл бұрын
I'm using compose 1.4.0-rc01, LazyVerticalGrid with coil. Grid is so laggy, Recycler view is much better, idk how is this stable (release build)
@VirgilioSolano
@VirgilioSolano Жыл бұрын
Thank you guys... awesome
@gregbar6583
@gregbar6583 Жыл бұрын
What would you advise to implement an "excel-type" two-dimension scrollable grid of constand grid size? It seem that nesting LazyRow in LazyColumn (or other way) is not good approach. Any suggestions?
@tomcat2096
@tomcat2096 2 жыл бұрын
Very helpful for me thanks Google
@PsijicV
@PsijicV 2 жыл бұрын
LazyGrid can't be used inside other scrollable even is I set userScrollEnabled = false.
@ДенисБекк
@ДенисБекк 2 жыл бұрын
Hi! When we can see the implementation of StaggeredGridLayout based on LazyLayout?
@AndroidDevelopers
@AndroidDevelopers 2 жыл бұрын
Thank you for the question! We are working on something like this. Keep an eye on our social media pages for updates!
@حميدبوعصيده-غ3ر
@حميدبوعصيده-غ3ر 2 жыл бұрын
can I get google developers training courses like Jetpack Compose for Android Developers as pdf documentation
@AndroidDevelopers
@AndroidDevelopers 2 жыл бұрын
Hi! You can check out the documentation for JetPack Compose and refer to it anytime on your journey here 😁: developer.android.com/jetpack/compose/documentation
@TheMikkelet
@TheMikkelet 2 жыл бұрын
HOW DO I UPDATE THE LIST WHEN I ADD/REMOVE ITEMS
@FrankOtten
@FrankOtten 3 ай бұрын
You must make sure your items are passed through as state. When one of the children gets removed or added after the initial load you bubble it up back to the parent by using lambda's as parameters for the add/remove actions. Once something within the state changes it will automatically re-compose for you (and only the items which have changed).
@adrian110288
@adrian110288 2 жыл бұрын
Great video. Thanks! I tried adding a custom Arrangement.Vertical to my app and that part shown on the video by Andrey worked well but then tried adding spacing to it like what Arrangement.spacedBy does and failed. Are there any examples of a custom arrangement with item spacing?
@andreykulikov9166
@andreykulikov9166 2 жыл бұрын
When you implement your own Arrangement.Vertical you can also override spacing property, it is defined on the same interface
@adrian110288
@adrian110288 2 жыл бұрын
@@andreykulikov9166 i have overriden the spacing property but still havent got the spacing applied. I was thinking I would need to factor the spacing in the calculations for outPositions?
@andreykulikov9166
@andreykulikov9166 2 жыл бұрын
@@adrian110288 yeah, you need to provide your spacing for the spacing property, this will be used when you have enough items to fill the whole viewport, and then also take into the account the spacing manually when you do the outPositions calculations for the case when you have less items than needed to fill the viewport
@StraplessReligion
@StraplessReligion 2 жыл бұрын
Is there a way to add space individual for rows ?
@andreykulikov9166
@andreykulikov9166 2 жыл бұрын
Could you please elaborate a bit more?
@AndroidDevelopers
@AndroidDevelopers 2 жыл бұрын
The two links provided here can help fill you in on how to add space in-between items and offer another helpful resource to aid you on your Compose journey! 😃 Content Spacing: developer.android.com/jetpack/compose/lists#content-spacing Arrangements: developer.android.com/reference/kotlin/androidx/compose/foundation/layout/Arrangement#public-functions_1
@dimidbrodsky9523
@dimidbrodsky9523 2 жыл бұрын
i cant import LazyHorizontalGrid in project?
@AndroidDevelopers
@AndroidDevelopers 2 жыл бұрын
Could you please check if you have added the following dependency to your project: "androidx.compose.foundation" and that you are running on the latest 1.2.0-beta02 Compose version? Thanks!
@mikeshilovski1512
@mikeshilovski1512 2 жыл бұрын
Magic
@ssverma1916
@ssverma1916 2 жыл бұрын
Damn good!
@USS_Daedalus
@USS_Daedalus Жыл бұрын
i should migrate my project to Compose 😮
@dimidbrodsky9523
@dimidbrodsky9523 2 жыл бұрын
why I can't add LazyRow in bottomsheet?
@AndroidDevelopers
@AndroidDevelopers 2 жыл бұрын
Hi Dimid, We are not aware of LazyRow incorrectly working inside a BottomSheet. Please file a bug in our bug tracker if you think you found it not working for you 🙂
@siva_subramaniam
@siva_subramaniam Жыл бұрын
bm - 5:21
@tashi7160
@tashi7160 2 жыл бұрын
i am too lazy now.
@aabhishek4911
@aabhishek4911 2 жыл бұрын
Where is this common performance gotchas talk they keep mentioning ,
@patryk11258
@patryk11258 2 жыл бұрын
EOQB8PTLkpY (ID of YT video)
@andreykulikov9166
@andreykulikov9166 2 жыл бұрын
kzbin.info/www/bejne/e4C0c2uGibGeprs
@andreykulikov1844
@andreykulikov1844 2 жыл бұрын
It is now called "Performance best practices for Jetpack Compose". You can find it on the same channel "Android Developers"
@FelipeBrunoRamirez
@FelipeBrunoRamirez Жыл бұрын
Hola soy felipe desanjoseterueltepeojuma puebla
@toystoryscarymovie-forkids3323
@toystoryscarymovie-forkids3323 Жыл бұрын
Beginner Friendly NOT!
@FrankOtten
@FrankOtten 3 ай бұрын
Yet Compose saves loads of time. I am reading through the entire docs section from the android developer website and it makes things very clear and easy. First I was like wtf is up with those remember items and stuff, then later I realized for like nearly all composables they made separate remember functions so you can easily re-use them in your composables for both re-usability and easy programming. I am still fairly new to programming but seeing how Compose works makes me quite enthusiastic!
@j2shoes288
@j2shoes288 5 ай бұрын
I understood what the woman was saying.
Fragments: The good (non-deprecated) parts
17:51
Android Developers
Рет қаралды 17 М.
Custom layouts and graphics in Compose
20:25
Android Developers
Рет қаралды 56 М.
Правильный подход к детям
00:18
Beatrise
Рет қаралды 11 МЛН
So Cute 🥰 who is better?
00:15
dednahype
Рет қаралды 19 МЛН
My scorpion was taken away from me 😢
00:55
TyphoonFast 5
Рет қаралды 2,7 МЛН
Tuna 🍣 ​⁠@patrickzeinali ​⁠@ChefRush
00:48
albert_cancook
Рет қаралды 148 МЛН
Thinking in Compose
25:27
Android Developers
Рет қаралды 87 М.
What's new in Android development tools
34:28
Android Developers
Рет қаралды 22 М.
Advanced state and side effects in Jetpack Compose
41:21
Android Developers
Рет қаралды 38 М.
Rules about performance tools - Android Developers Backstage
1:10:15
Android Developers
Рет қаралды 3,9 М.
Fundamentals of Compose Layouts and Modifiers - MAD Skills
11:56
Android Developers
Рет қаралды 104 М.
Google's New AI is Transforming Streaming and Search
9:16
Ian Sinnott
Рет қаралды 1,6 М.
Compose Modifiers deep dive
21:02
Android Developers
Рет қаралды 36 М.
State in Jetpack Compose
43:46
Android Developers
Рет қаралды 76 М.
Deep dive into Jetpack Compose layouts
28:25
Android Developers
Рет қаралды 61 М.
Правильный подход к детям
00:18
Beatrise
Рет қаралды 11 МЛН