I don't understand your question. The alert title is set when you present the alert. Why would you change it? The dismiss is done when one of action buttons is tapped. If there is no action button specified, a cancel button is always there by default.
@@StewartLynch Many thanks for your reply. I have an application that assigns a series of tasks to the user through an alert. For example, if the user is not aware of one of the alert, or does not react, the user should be shown the specific alert at the specified time, rather than remaining on the old alert. The best way for doing that is to update alert message or dismissing the old one and creating a new alert which I don't prefer this way.
@@StewartLynch Thanks for the quick reply! My question was not how to display the data. It was how to get the data. With alert i see that “presenting:” or not mentioned in this video but “item:” holds the response object. But without using .alert(…), how can i get it? That was the question. Thank you!
@@ER-bi9ir then I don’t understand the question Eric. This tutorial is about alerts so what are you presenting? Feel free to DM me on Twitter @StewartLynch to continue the conversation
I want to cover all things. What is easy for you, may not be easy for someone else. This new version of alert is different from the iOS 14 version so I think it is worth pointing out. You will see in videos coming later how I use this new alert type in a different way to display errors to your users.
Hey Stewart! I am very very thankful to you. I learned a lot from you and still learning. I got my first iOS Developer job. So thanks to you too. Please buy some Sweets and Sweeten your mouth. ☺
Great insight in the new alerts. Especially the last one with the parameter presentData opens a whole set of new possibilities. I have not been able to reproduce the same behavior in the first alerts as you do in the video. I systematically get an OK button by default, and not a Cancel. It has probably something to do with different versions: I use Xcode 13 (not beta5) on Monterey beta 8 (was released on Sept 28, after you have published the video) . On an Intel MacMini2018.
Thanks for this. This is the only video so far I came across on SwiftUi alerts that go beyond the surface level things that everyone talks about.
Glad it was helpful!
Thanks for this great tutorial , I have two question regarding to alert iOS 15 : 1- How to update Message title ? 2- How to dismiss an alert ?
I don't understand your question. The alert title is set when you present the alert. Why would you change it? The dismiss is done when one of action buttons is tapped. If there is no action button specified, a cancel button is always there by default.
@@StewartLynch Many thanks for your reply. I have an application that assigns a series of tasks to the user through an alert. For example, if the user is not aware of one of the alert, or does not react, the user should be shown the specific alert at the specified time, rather than remaining on the old alert. The best way for doing that is to update alert message or dismissing the old one and creating a new alert which I don't prefer this way.
@@sherkorahman2166 I am not sure you can accomplish what you were trying to do with alerts. They don’t work that way.
Real nice video.
Give's me everything i wanted to know.
You're an excellent help.
2:27 Which app you mention for the icons? Couldn't understand it.
It is called Bakery. I have added a link to the description too. apps.apple.com/ca/app/bakery-simple-icon-creator/id1575220747?mt=12
Great tutorial. What can I do if I want to get the response back without using .alert?
You need to create your own view that you can conditionally present using a ZStack.
@@StewartLynch Thanks for the quick reply! My question was not how to display the data. It was how to get the data. With alert i see that “presenting:” or not mentioned in this video but “item:” holds the response object. But without using .alert(…), how can i get it? That was the question. Thank you!
@@ER-bi9ir then I don’t understand the question Eric. This tutorial is about alerts so what are you presenting? Feel free to DM me on Twitter @StewartLynch to continue the conversation
Strange is that, you usually make videos for "advanced" tasks, but this one is relatively easy.
I want to cover all things. What is easy for you, may not be easy for someone else. This new version of alert is different from the iOS 14 version so I think it is worth pointing out. You will see in videos coming later how I use this new alert type in a different way to display errors to your users.
@@StewartLynch It is worth, I never argued.
What if I’m developing app with Xcode 12.5 for iOS 14 and above. My alerts will not work on iOS 15?
I your target is still iOS 14, the older API will still work with devices running iOS 15.
@@StewartLynch thank you
Thank you Stewart...
You are very welcome
Thank you.
this is amazing thank you
Hey Stewart! I am very very thankful to you. I learned a lot from you and still learning.
I got my first iOS Developer job. So thanks to you too. Please buy some Sweets and Sweeten your mouth. ☺
That is fantastic news. Congratulations.
@@StewartLynch I'll buy coffee for you with me first salary. ☺
Great tutorial. One note - it's "deprecated", not "depreciated" 😉
yah, I was hoping no one would catch that.
@@StewartLynch Literally the first thing I noticed. Don't worry. Everyone at the company I work at kept saying the same thing to start with.
I have come a long way since I created that video. I won’t make that mistake again LOL
The links to the starter project take you to the wrong project. It takes you to the SwiftUI Layout project.
Oops. Sorry about that. Fixed now
Funny you’re using the word deprecIated, were Apple uses deprecated.
Yes, I made that mistake. Deprecated is the correct term.
Great insight in the new alerts.
Especially the last one with the parameter presentData opens a whole set of new possibilities.
I have not been able to reproduce the same behavior in the first alerts as you do in the video.
I systematically get an OK button by default, and not a Cancel.
It has probably something to do with different versions: I use Xcode 13 (not beta5) on Monterey beta 8 (was released on Sept 28, after you have published the video) . On an Intel MacMini2018.