Glad to see you doing Jetpack Compose! Just starting to look at it, but looks like a load of refactoring will be needed! Also, great to hear you on the Fragmented podcast! 👍👍
You mentioned the video number on the thumbnail, that's a good idea, it will give u immediate insight like that its a part of a playlist...as always u r a great teacher...thnx mitch
Amazing work Mitch!! I like this series. I do have some suggestions for enhancements: * In the image API, it is easier to use bitmap = imageResource(id= R.drawable.imagename). Rather than use imageFromResource( … ) * In Text API you do not need to call the “text= …” every time. Compose is mart enough to know that when you write a text in double quotation that it is the text without specifying. * In the Text API, it is useful to define all TextStyles inside the UI/Type.kt file. Then specify what style to use in the text by defining the “style = …” then we call the style we defined like this “style = typography.h1 or whatever other styles you defined, style body1 may be. * In Text API again :( , we can specify the fontSize = 16.sp directly without the text unit. Keep up the good work.
Some how the scrollable column was not available for me. So I had to use the following for that. Thanks Mitch. Keep up the good work. Stay safe. setContent { Column(modifier = Modifier .fillMaxHeight() .fillMaxWidth() .background(Color(0xFFF2F2F2)) .verticalScroll( rememberScrollState() )) { Image( painter = painterResource(id = R.drawable.happy_meal_small), contentDescription = "none", modifier = Modifier.height(250.dp), contentScale = ContentScale.Crop ) Column(modifier=Modifier.padding(16.dp)) { Text("Happy meal", style= TextStyle(fontSize = 26.sp)) Spacer(modifier = Modifier.padding(top = 10.dp)) Text("800 Calories", style= TextStyle(fontSize = 17.sp)) Spacer(modifier = Modifier.padding(top = 10.dp)) Text("$5.99", style= TextStyle(fontSize = 17.sp), color = Color(0xFF85bb65)) } } }
Hi I am a paid member and I support you! I have just started, I hope it is not outdated. As soon as I start at 4:30 I could only make it work with following code: Image(painter = painterResource(id = R.drawable.happy_meal), contentDescription = "") Please go through your project and check for outdated code thank you. Keep up the good work ;)
Later on: Unresolved reference: ScrollableColumn, Also it took me time to change font size (i had to figure out how to make it work) so I will ask for a refund totally disappointed unfortunately....
@@ssSFrankSss What will you ask refund for LOL :p. This is a free course. Please use Google if you face any such issue. Compose was in alpha, and there are a lot of API changes, until an API is stable. Solution is to use Column(modifier = Modifier.verticalScroll(rememberScrollState())) instead of ScrollableColumn
Pretty sure some of this is out of date now my code seems to work just trying to brush up on compose after coming from xml way of doing things here is my code as of today (in setContent{}): setContent { Column( modifier = Modifier .verticalScroll( state = ScrollState(0), enabled = true ) .background(color = Color(0xFFF2F2F2)) .fillMaxSize() ) { Image( painterResource(id = R.drawable.happy_meal_small), contentDescription = "", modifier = Modifier.height(300.dp), contentScale = ContentScale.Crop ) Column(modifier = Modifier.padding(16.dp)) { Text( text = "Happy Meal", style = TextStyle( fontSize = 26.sp ) ) Spacer(modifier = Modifier.padding(8.dp)) Text( "800cal", style = TextStyle( fontSize = 18.sp ) ) Spacer(modifier = Modifier.padding(8.dp)) Text( "£5.99", style = TextStyle( color = Color.DarkGray, fontSize = 18.sp ) ) } } }
Very nice video - to the point and real hands-on. 1 thing worth notice with this kind of declarative-style UI development ( which i did in react-native and Flutter for 2 apps) is that the only way to test your UI changes is by running an app on to device/emulator. Is there an equivalent of "design preview" which we are used to in the Android Studio Layout editor that you might have came across for these declarative-style UI development tools - such as Jetpack compose or Flutter?
Hey Mitch, first of all, thank you. So Android is getting rid of the Layouts, XML files? This is fun to develop but kind of dragging the components on the screen was faster? I am so confused now. Can you explain?
is there any bug in android studio canary 4.2? cause whenever i make changes in jetpack compose app i need to uninstall the app and then have to install it again in order to see changes. I'm not able to see changes after running app or instant run feature.
I have problems 1. I don't know why, but my newest compose version 1.0.0-beta01 cannot use bitmap = imageResource But I use Image(painterResource(id = ...), contentDescription) 2. ScrollableColumn not found, instead I found in documentation use Column(Modifier.verticalScroll(rememberScrolLState()) My God, I hope they don't make too much changes.... Why Developing Android always like this though
This line "Image(bitmap = imageResource(res = resources,resId = R.drawable.happy_meal_small),null)" is not working anymore... :-(. There are other ways to draw images
Hi, I want to fix which i have missed. As where i have learnt android my mentor was a fake teacher and he told me all the bad practices. I am good with linear and Relative layout but when i made a bigger project then i realise to make a responsive design and compatible we have to use Constraint Layout. Can jetpack eliminate my weakness for Constraint layout and coordinator layout?? Jetpack Seems like a bootstrap Grid System
Thank you, good tutorial, Im just giving my humble 2 cents for what its worth, please don't take it the wrong way. Your tutorials are great, but it would be better if you stuck to the subject and kept them to the point. If its about Columns, its better to explain columns in depth and then show how it could be practically applied to a realistic theme. This entire 17 minute video, I learnt nothing about the basics about Column Layouts, nothing about arrangement, alignment, how to customise that by spacing it by x/y axis? A lot of Time goes in making this fancy layout, it becomes distracting as the tutorial ends up about layouts and not columns If you have covered these concepts, than it must have completely slipped my mind as I got distracted. For example: Too much time spent on images and text styling instead of talking about Columns, not learnt much Otherwise, your tutorials have been very helpful
i was sold with the drawing.
I should have been an artist
For newer versions image is loaded by :
Image(
painter = painterResource(id = R.drawable.happy_meal_small),
contentDescription = "Happy Meal"
)
thanks
Hey, Mitch! You are my best teacher now !
Glad to see you doing Jetpack Compose! Just starting to look at it, but looks like a load of refactoring will be needed! Also, great to hear you on the Fragmented podcast! 👍👍
You mentioned the video number on the thumbnail, that's a good idea, it will give u immediate insight like that its a part of a playlist...as always u r a great teacher...thnx mitch
Amazing work Mitch!! I like this series. I do have some suggestions for enhancements:
* In the image API, it is easier to use bitmap = imageResource(id= R.drawable.imagename). Rather than use imageFromResource( … )
* In Text API you do not need to call the “text= …” every time. Compose is mart enough to know that when you write a text in double quotation that it is the text without specifying.
* In the Text API, it is useful to define all TextStyles inside the UI/Type.kt file. Then specify what style to use in the text by defining the “style = …” then we call the style we defined like this “style = typography.h1 or whatever other styles you defined, style body1 may be.
* In Text API again :( , we can specify the fontSize = 16.sp directly without the text unit.
Keep up the good work.
Theming stuff is coming later
Mitch exposing his artistic skills
This looks like flutter in native!!
Yeah pretty much
@@codingwithmitch
we can use xml instead
why usinq jetpack compose
@@testwhwhja You can also light a fire by rubbing stones, why do you use a lighter?
@@thearpansircar 😂 dope
Exactly, so what will happen, flutter adopted as native 🙄
Keep it up! First programming series from a long time that I enjoy listening. 👍
This is so much more pleasing than XML
I want to say really really thank you so much, my friend,
I learn many things from you,
I love you so much, you are the best in the world
Your caption images are exceptional. I like each one of them
Some how the scrollable column was not available for me. So I had to use the following for that. Thanks Mitch. Keep up the good work. Stay safe.
setContent {
Column(modifier = Modifier
.fillMaxHeight()
.fillMaxWidth()
.background(Color(0xFFF2F2F2))
.verticalScroll(
rememberScrollState()
)) {
Image(
painter = painterResource(id = R.drawable.happy_meal_small),
contentDescription = "none",
modifier = Modifier.height(250.dp),
contentScale = ContentScale.Crop
)
Column(modifier=Modifier.padding(16.dp)) {
Text("Happy meal", style= TextStyle(fontSize = 26.sp))
Spacer(modifier = Modifier.padding(top = 10.dp))
Text("800 Calories", style= TextStyle(fontSize = 17.sp))
Spacer(modifier = Modifier.padding(top = 10.dp))
Text("$5.99", style= TextStyle(fontSize = 17.sp), color = Color(0xFF85bb65))
}
}
}
Thank you
thanks man
Hey Mitch, here’s your engagement ;)
Seriously amazing content! Very grateful to you.
Hi I am a paid member and I support you! I have just started, I hope it is not outdated. As soon as I start at 4:30 I could only make it work with following code: Image(painter = painterResource(id = R.drawable.happy_meal), contentDescription = "")
Please go through your project and check for outdated code thank you. Keep up the good work ;)
Later on: Unresolved reference: ScrollableColumn, Also it took me time to change font size (i had to figure out how to make it work) so I will ask for a refund totally disappointed unfortunately....
@@ssSFrankSss What will you ask refund for LOL :p. This is a free course. Please use Google if you face any such issue. Compose was in alpha, and there are a lot of API changes, until an API is stable. Solution is to use
Column(modifier = Modifier.verticalScroll(rememberScrollState())) instead of ScrollableColumn
I'm currently studying flutter but I got more interested in compose just after watching this video.
Thank you for explaining from a very basic level.
Here is your engagement,
Thanks...
now going to see your next video on same topic :D
Here's your engagement. Best of luck, Mitch 👍
Pretty sure some of this is out of date now my code seems to work just trying to brush up on compose after coming from xml way of doing things here is my code as of today (in setContent{}):
setContent {
Column(
modifier = Modifier
.verticalScroll(
state = ScrollState(0),
enabled = true
)
.background(color = Color(0xFFF2F2F2))
.fillMaxSize()
) {
Image(
painterResource(id = R.drawable.happy_meal_small),
contentDescription = "",
modifier = Modifier.height(300.dp),
contentScale = ContentScale.Crop
)
Column(modifier = Modifier.padding(16.dp)) {
Text(
text = "Happy Meal",
style = TextStyle(
fontSize = 26.sp
)
)
Spacer(modifier = Modifier.padding(8.dp))
Text(
"800cal",
style = TextStyle(
fontSize = 18.sp
)
)
Spacer(modifier = Modifier.padding(8.dp))
Text(
"£5.99",
style = TextStyle(
color = Color.DarkGray,
fontSize = 18.sp
)
)
}
}
}
Hi Flutter :p. I love it!! This changes all for Android native develop :D
Hey mitch. This Jetpack Compose sounds great.
Great Introduction Mitch.
PS: I like your shirt, it's looking very good.
Thanks 😬
Hey, Mitch! Nice Tutorial Brother.
You become more better on how to explain things on android. Maybe you can upload vids about your workout routine. Stay safe Android Mitch!
Very nice video - to the point and real hands-on. 1 thing worth notice with this kind of declarative-style UI development ( which i did in react-native and Flutter for 2 apps) is that the only way to test your UI changes is by running an app on to device/emulator. Is there an equivalent of "design preview" which we are used to in the Android Studio Layout editor that you might have came across for these declarative-style UI development tools - such as Jetpack compose or Flutter?
Hey Mitch
Thank you for amazing tutorials.
Don't you think this approach is adding UI related boilerplate in Activities or Fragments instead of layout xml?
No it's superior
You can do all of this with composable functions as well, so this does not have to be inside a fragment / activity..
Nice work on this Mitch. But, yes, a lot of refactoring is needed. Will still be following this tutorial though.
Hello Mitch, thank you for the amazing tutoring. 😁
👍 amazing drawing skills 😂
Great work 👍
I just wanted to say thank you
Hey Mitch.. you are the best!!
Incredible mitch!
Mitchy and his osm drawing skills 😍🤪
Great example
The emulator crashes due to very large Image , simply move the image to mipmap and it will work fine
Greate tutorial :3
YOU ARE THE BEST.
awesome mitch !
Hey mitch, here's your engagement, XD. oh btw, isn't there any way to allow like and comments from your website?
Hey Mitch, here's your engagement!
Thank you for usual useful video.
Still i didn't get why should i switched to jetpack compose ?
is that easier than constraint layout ?
Overall yes I'd say layout building is much more pleasurable with compose. Also the animation capabilities are simpler
Hey mitch! Here's your engagement 😂
make a playlist with all of your jetpack compose videos
You are the best man
Hey Mitch, first of all, thank you. So Android is getting rid of the Layouts, XML files? This is fun to develop but kind of dragging the components on the screen was faster? I am so confused now. Can you explain?
that's good for the start
*thanks*
is there any bug in android studio canary 4.2? cause whenever i make changes in jetpack compose app i need to uninstall the app and then have to install it again in order to see changes. I'm not able to see changes after running app or instant run feature.
Check this - developer.android.com/jetpack/videos/jetpack-compose-preview.mp4
Great lesson, thank you a lot!
Thanks a lot for your effort
I came like Android view -> Flutter -> Compose. Due to familiarity with Flutter, many fundamental doubts got cleared.
there is a code lab called "Layouts in Jetpack Compose" could you explain it into your tutorials as it was a little bit complex to me
Thanks, Mitch
Hey Mitfh! Here is your engagement!
thanks for the video man
Hey Mitch. keep up the good work. and keep that beard it looks great on you, man!
Low key got hungry at 1:14
Hy mitch it is awesome!!!!
In my project, I'm defining a toolbar on my styles xml file.
When I rotate my screen, the image is bellow the toolbar.
Any idea why this is happening?
What makes Compose better than the old XML layouts?
I have problems
1. I don't know why, but my newest compose version 1.0.0-beta01 cannot use bitmap = imageResource
But I use Image(painterResource(id = ...), contentDescription)
2. ScrollableColumn not found, instead I found in documentation use
Column(Modifier.verticalScroll(rememberScrolLState())
My God, I hope they don't make too much changes....
Why Developing Android always like this though
But if we need to create more more complex row in list how to do that
Thanks!
which one is the previous video? How can I go to the previous video ???
Love it thanks
Awesome, thank you!
Very cool, thank you
Hey Mitch, here's your engagement
Lets go!
Hey Mitch, Here's your engagement :)
It reminds me of flutter a lot!
Love you Mitch! However so many things have been replaced
ScrollableColumn is deprecated in the new version of compose
What does the layout inspector show?
Amazing, thanks 👍
Thanks ❤️
important information
Hey mitch here is your engagement.
Superb
This line "Image(bitmap = imageResource(res = resources,resId = R.drawable.happy_meal_small),null)" is not working anymore... :-(. There are other ways to draw images
I just fixed setContnet issue, Now imageFromResources not found :(
Best video
Here is the engagement bro lol
Hey mitch here is your engagement
Hi, I want to fix which i have missed. As where i have learnt android my mentor was a fake teacher and he told me all the bad practices. I am good with linear and Relative layout but when i made a bigger project then i realise to make a responsive design and compatible we have to use Constraint Layout. Can jetpack eliminate my weakness for Constraint layout and coordinator layout?? Jetpack Seems like a bootstrap Grid System
Ya similar to bootstrap grid system
Is there margin property in compose or just padding ?
Just padding
I heard the last bit as "Hey bitch, here's your engagement"
You heard correctly
hii mitch here is you engagement
Hello, thanks for this amazing totorial. If you have some challenges in your course, it would be the the best tutorial on Earth:)
Can we see our design in studio or not?? Or we need to run our application to see our changes every time 🙄🙄
giving me react-native vibes.
Thank you, good tutorial, Im just giving my humble 2 cents for what its worth, please don't take it the wrong way. Your tutorials are great, but it would be better if you stuck to the subject and kept them to the point.
If its about Columns, its better to explain columns in depth and then show how it could be practically applied to a realistic theme.
This entire 17 minute video, I learnt nothing about the basics about Column Layouts, nothing about arrangement, alignment, how to customise that by spacing it by x/y axis?
A lot of Time goes in making this fancy layout, it becomes distracting as the tutorial ends up about layouts and not columns
If you have covered these concepts, than it must have completely slipped my mind as I got distracted.
For example: Too much time spent on images and text styling instead of talking about Columns, not learnt much
Otherwise, your tutorials have been very helpful
Oi, I don't care if anyone makes a "no one cares" reply, but I am second comment.
hi
@@codingwithmitch hi
I got this error:
Unresolved reference: happy_meal_small
🤔🤔🤔🤔🤔🤔🤔🤔🤔
Then you didn't add the image
@@codingwithmitch No, I added it, but anyway the problem is solved. I think the problem was with mix name in import
comment for the algorithm
0:48
lol accidentally clicked the "back" button
It looks like flutter
Basically 😂
Oh no, This is the exact reason why I stopped using flutter!
Well, you don't have to use it. Layout.xmls still exist and will
5:18 there is no image composable with bitmap
sorry my bad i was using a older version of compose.
Don't like it. xml + viewBinding much better for me.
To each their own
RIP Xml