I think I'm at the stage where I would pay for sup...
# compose
v
I think I'm at the stage where I would pay for support to help me understand compose/livedata/room/state/flow stuff! Does such a service exist anywhere? A one-to-one discussion?
💰 1
I'm finding it very hard to even articulate the difficulties in having in my understanding. Perhaps I'm too old. I'm a very procedural-minded developer.
s
Yeah also important to note that these things can be quite different from each other. Understanding Flows and coroutines is one thing, and understanding compose state is another. Then putting them together is yet another. I’d suggest you try and understand Flows first, and then the rest will fall into place. Especially since you say that you also have issues understanding Room, which I assume again it’s the flows part of it. You can completely skip LiveData I think at this point, at least we’ve done that on our project. And as far as sources go, not sure, the official android docs are great in general imo, but one thing that stood out for me was this series https://code.cash.app/rx-to-coroutines-concepts. I don’t even know RX, but still this let me understand a bunch of things about coroutines.
v
Thank you. I'll take a look. LiveData is still in a lot of the official documentation. And I often want to fetch a value from the database - an ID - not a continuously updating or dynamic list of objects. My use case is: fetch an ID stored in a table, then fetch the entity with that ID from a different table. So I don't need a flow of IDs... do I?
s
If you want a one shot operation, room gives you the ability to simply mark the function as suspend and you get the one shot value perfectly fine.
v
Thank you Stylianos. I think the documentation pushes you to LiveData. I've taken that out and replaced it with suspend functions where needed. And it's behaving much better, and simpler code. Still got lots to learn - I don't think it's fully "sunk in" to my brain yet.
I'd still pay for a code review... 💰!
s
Hmm interesting that you’ve had this feeling from reading the docs, I feel like I haven’t seen a LiveData declaration in months 😅 Might be me just filtering it out from my brain though 😄 And yeah, it doesn’t “sink in” that fast, but it will eventually, it definitely took me a while, and there’s still so much to learn, as always. It’s gonna be hard to find someone even to pay them to help you. I find it that before you know enough on a topic, it’s hard to be taught by a random person since you may not know enough to at least recognize if they’re saying wrong things or not, so that’s always scary. Gl finding someone though 😊