SwiftUI Confirmation Dialog | iOS 15

preview_player
Показать описание

In today's video I show you how to use the new Confirmation Dialog introduced in iOS 15 for SwiftUI. I think this is a much cleaner way to handle a very common type of alert so it doesn't overtake the entire screen, which leads to a much nicer user experience.

This tutorial was created in Xcode 13 and iOS 15.

If you like my teaching or presentation style, I've started creating my own courses:

Twitter:

Link to my book - How I Became an iOS Developer:

Timestamps
0:00 - What You Will Learn
0:19 - Starter Project & Alert Problem
1:50 - Confirmation Dialog Code

Book and learning recommendations that help out the channel if you decide to purchase (Affiliate Links):

Paul Hudson's Hacking With Swift:

Donny Wals - Combine:

Mark Moeyken’s SwiftUI Books:

Ray Wenderlich Books:

Links to my iOS Dev Setup & iOS Dev Book Recommendations

#swift #softwaredeveloper #iosdeveloper
Рекомендации по теме
Комментарии
Автор

Glad that you made this! The missing title in my Confirmation Dialog had me confounded...titleVisibility was needed.

GaryLutchansky
Автор

Cool! I’m waiting every your videos so much)

БорисЗиновьев-сх
Автор

Please start tutorials for apple watch development

muhammadtayyab
Автор

Is it possible with swiftui to make apple's like delete action with conf. dialog?

nebojsapavlovic
Автор

How can you change the color of the confirmationDialog buttons, foregorundColor or accentColor does not work

stavroschios
Автор

Hey, Thanks for your videos. I want to start a new project but although I'm developing for a couple of years I'm still not sure about SwiftUI ! . Do you think that it is the time we can start a new project with swift UI vs UIkit?

sajjadsarkoobi
Автор

Very nice explanation.
But can you also use 2 buttons on the confirmation dialog.
For example one for delete and one for cancel ??

Thanks a lot :)

erichsnijder
Автор

Is there a way to add a system Image icon to these buttons?

roushfenwayfan
Автор

Hey Sean, any chance in getting a video going over CloudKit?

Connor-pjtg
Автор

Unfortunately because the confirmation dialogue is triggered by a single Boolean, it does not work well on items in a list.

rickywitherspoon
Автор

Wow, really weird - no matter what iPad I use, the standard confirmation dialog (at the bottom) always appears. Hmmm, not sure what I did wrong.

SBSanook