SwiftUI tutorial for Beginners - @State vs @Binding - How to pass data between views?

preview_player
Показать описание
In this video we will see a coding example with SwiftUI. We will make a little photo editor application and use sliders to change the image brightness and add a blur effect. We will create a subview.
By the end of this video you will understand when to use @State and @Binding. It is also good to understand why for some cases it is enough to declare you properties as let constants.

Overview
00:00 introduction
04:52 @State property
11:06 creating subviews
12:20 using @Binding with property
15:21 let property
23:20 wrap up

If you liked what you learned and you want to see more, check out one of my courses!

#SwiftUI #iOSDevelopment
Рекомендации по теме
Комментарии
Автор

Hi from Morocco, thank you for all your tutorials, I found the helpful.

AmineCcht
Автор

Thank you very much for the video and the explanation between the different ways to pass data between views !

VlasiosSokorelosTheDarkwavist
Автор

better than bootcamps and pricey courses, amazing.. thank you

ekinyil
Автор

Thank you for the video! Loud and clear :)

katesychenko
Автор

thanks for the video, can you please provide the documents that helped you to understand it ?

moshikof
Автор

Great Video as always, but is it possible to get your Scribble proppertyWrapper.jpg ?? Would be really helpful to decide what Wrapper you should use. Danke :)

devjulianschmid
Автор

Terrific work! Thanks for taking the time to share. 🙏

CraigTemple
Автор

You had me at the kitten pictures! I really enjoy your videos, keep them coming, great work!!

theocrevon
Автор

Your videos are always on point. Amazing work!

MrMysical
Автор

Karin, thanks you so much for your efforts. You are doing such a great job!

antonsergeyev
Автор

Thanks for your video tutorial. Your explanation as well as example code is very clear and to the point.

kenjyfukuda
Автор

I'm wondering about calling methods from within subviews, especially in an MVVM context. Let's say that the slider also needed to call some function on the PhotoEditorViewModel. Would you pass in the viewmodel and then call it from within the subview like: vm.someMethod() ?

toastrecon
Автор

Thanks!
Great videos! looking forward to more :)
greetings from mainz

Mitglied
Автор

At 1:01 of the video you said I could find pictures of the video in the description. I can't find them. Is there any way you can help with that?

oleksandrpronin
Автор

i dont understand why there is no initializer in the struct you created

gdrcht
Автор

Hi Karin! Do you provide courses at Udemy, as well?

rapier
Автор

Shouldn't your @State and @Binding properties be private?

gamblethedog
Автор

Hello Ma’am, I stuck in my project. How to enable button once every 2 hours, when user tap on then button is disabled for next 2 hours? Please make a video in SwiftUI !

markme
Автор

she does all the other stuff and missing out the main thing we have to skip skip skip skip forever until we actually see she's using the binding

prettygirl
Автор

Please use dark mode on your tutorials. I really like your teaching style and want to follow but lıght mode burns my eyes. Please

benceylan