A Full Tour of NavigationStack , NavigationLink and navigationDestination - SwiftUI tutorial

Karin Prater November 15, 2022
Video Thumbnail
Karin Prater Logo

Karin Prater

View Channel

About

I create advanced iOS tutorials that help you build smarter apps. New videos drop weekly, with hands-on examples you can actually use at work. No fluff — just smart, practical content for experienced devs who want to grow. What you’ll find here: - How SwiftUI works under the hood - Performance and testing strategies - Async/await vs Combine — real-world comparisons - Deep dives into new Apple APIs - Scalable architecture & design patterns (MVVM, dependency injection, clean code) - Design thinking for developers I have a PhD in physics and started out in clean rooms and laser labs — but discovered I loved coding more than microprocessing. I taught myself iOS to build my own app, then worked at an iOS agency where I learned how teams ship real products. Now I run this channel full-time, sharing the lessons I’ve learned and the ones I’m still figuring out. If that sounds like something that could help you grow as an iOS developer, then make sure to join me by subscribing!

Video Description

WWDC 2022 gave us a new Navigation API. In this SwiftUI tutorial I will show extended examples for NavigationStack. This works with the new value-based NavigationLink and navigationDestination. NavigationStack allows access to the NavigationPath, which you can use to implement programmatic navigation. It is much easier and cleaner to use than the deprecated NavigationView. 👉 read the corresponding blog post https://www.swiftyplace.com/blog/better-navigation-in-swiftui-with-navigation-stack Additional resources: WWDC The SwiftUI cookbook for navigation https://developer.apple.com/videos/play/wwdc2022/10054/ Overview 00:00 introduction 03:45 project set up 05:47 NavigationLink with value and navigationDestination 15:17 multilevel navigation stack 16:19 programmatic navigation with NavigationPath 21:46 custom back button 28:07 NavigationStack with custom type NavigationPath 35:04 complex navigation state 56:45 state restoration with @SceneStorage, Combine and Async Await 1:08:58 summary If you liked what you learned and you want to see more, check out one of my courses! 👨‍💻 my SwiftUI course https://learn.swiftyplace.com/swiftui-layout-course 👨‍💻 my Core Data and SwiftUI course https://learn.swiftyplace.com/swiftui-core-data-mastery-course ⬇️ Project files: https://github.com/gahntpo/NavigationStackProject #SwiftUI #Navigation #NavigationStack

You May Also Like

SwiftUI Development Must-Haves

AI-recommended products based on this video

Loading...
140W C to C Super Fast Charger,Compatible with MacBook Pro 16, 15, 14, 13 Inch, MacBook Air 13 Inch, iPad Pro 2021/2020/2019/2018, Lenovo and All Type C Devices 7.2ft

140W C to C Super Fast Charger,Compatible with MacBook Pro 16, 15, 14, 13 Inch, MacBook Air 13 Inch, iPad Pro 2021/2020/2019/2018, Lenovo and All Type C Devices 7.2ft

(1,273)
$28.49
FREE delivery Sat, Jun 14 on your first order
400+ bought in past month
Loading...
for iPhone 16/15 Pro Max Charger, 20W Fast Charging USB C Charger Block Wall Power Adapter + 6FT USB-C Cable for iPhone 16 Pro Max Plus 16e, iPhone 15 Pro Max, iPad Pro 12.9/11/13 inch, Air 4/5

for iPhone 16/15 Pro Max Charger, 20W Fast Charging USB C Charger Block Wall Power Adapter + 6FT USB-C Cable for iPhone 16 Pro Max Plus 16e, iPhone 15 Pro Max, iPad Pro 12.9/11/13 inch, Air 4/5

(3,858)
$19.99
FREE delivery Sat, Jun 14 on your first order
1K+ bought in past month
Loading...
ProCase Smart Case for iPad mini 7 A17 Pro 2024/ Mini 6 2021 8.3 Inch, Hard Back Cover for iPad mini 8.3" 7th Gen A2995/A2996/A2993/6th Gen A2567 A2568 A2569 -Navy

ProCase Smart Case for iPad mini 7 A17 Pro 2024/ Mini 6 2021 8.3 Inch, Hard Back Cover for iPad mini 8.3" 7th Gen A2995/A2996/A2993/6th Gen A2567 A2568 A2569 -Navy

(7,456)
$13.99
FREE delivery Sun, Aug 10 on your first order
100+ bought in past month
Loading...
ProCase Smart Case for iPad mini 7 A17 Pro 2024/ Mini 6 2021 8.3 Inch, Hard Back Cover for iPad mini 8.3" 7th Gen A2995/A2996/A2993/6th Gen A2567 A2568 A2569 -Black

ProCase Smart Case for iPad mini 7 A17 Pro 2024/ Mini 6 2021 8.3 Inch, Hard Back Cover for iPad mini 8.3" 7th Gen A2995/A2996/A2993/6th Gen A2567 A2568 A2569 -Black

(7,456)
$13.99
FREE delivery Sun, Aug 10 on your first order
100+ bought in past month
Loading...
MOSISO Laptop Case 13 inch, 13 inch Laptop Sleeve Bag Compatible with MacBook Air 13 M4 M3 M2 M1 2025-2018 / Pro 13 M2 M1 2025-2016, Neoprene Computer Sleeve Bag with Small Case, Space Gray Global Recycled Standard

MOSISO Laptop Case 13 inch, 13 inch Laptop Sleeve Bag Compatible with MacBook Air 13 M4 M3 M2 M1 2025-2018 / Pro 13 M2 M1 2025-2016, Neoprene Computer Sleeve Bag with Small Case, Space Gray Global Recycled Standard

(20,392)
$24.29$21.88
FREE delivery Sun, Aug 10 on your first order
Loading...
MOSISO Compatible with MacBook Air 13 inch Case 2021, 2020-2018 Release A2337 M1 A2179 A1932, Plastic Hard Shell&Keyboard Cover&Screen Film&Storage Bag for MacBook Air 13.3 inch Case, Crystal Clear

MOSISO Compatible with MacBook Air 13 inch Case 2021, 2020-2018 Release A2337 M1 A2179 A1932, Plastic Hard Shell&Keyboard Cover&Screen Film&Storage Bag for MacBook Air 13.3 inch Case, Crystal Clear

(2,431)
$14.52
FREE delivery Sat, Jun 14 on your first order
200+ bought in past month
Loading...
tomtoc 360° Protective Laptop Sleeve for 13-inch New MacBook Air M4/A3240 2025, M3/A3113, M2/A2681 M1/A2337 A2179 A1932, 13-inch MacBook Pro M2/A2686 M1/A2338, Water-Resistant Computer Case Bag Global Recycled Standard

tomtoc 360° Protective Laptop Sleeve for 13-inch New MacBook Air M4/A3240 2025, M3/A3113, M2/A2681 M1/A2337 A2179 A1932, 13-inch MacBook Pro M2/A2686 M1/A2338, Water-Resistant Computer Case Bag Global Recycled Standard

(12,952)
$36.07
PrimeFREE delivery Sat, Jun 14
100+ bought in past month
Loading...
MOSISO 13-14 inch Laptop Case, 13.3 inch Puffy Laptop Sleeve Compatible with MacBook Air 13 13.6 M4 M3 M2 M1/Pro 13/Pro 14,HP,Dell,ASUS, Lenovo, Polyester Horizontal Bag with Small Case, Rose Red Global Recycled Standard

MOSISO 13-14 inch Laptop Case, 13.3 inch Puffy Laptop Sleeve Compatible with MacBook Air 13 13.6 M4 M3 M2 M1/Pro 13/Pro 14,HP,Dell,ASUS, Lenovo, Polyester Horizontal Bag with Small Case, Rose Red Global Recycled Standard

(918)
$31.04
FREE delivery Tue, Jun 17 on your first order
Loading...
Metapen Air 8 Apple Pencil for iPad 2018-2025, 20H Battry Life, 2Min Fast Charging, Palm Rejection, Stylus Pen for iPad 11/10/9/8/7/6th, iPad Pro 12.9/11/13“M4, iPad Air 3/4/5/6/M2/M3, iPad mini 5/6

Metapen Air 8 Apple Pencil for iPad 2018-2025, 20H Battry Life, 2Min Fast Charging, Palm Rejection, Stylus Pen for iPad 11/10/9/8/7/6th, iPad Pro 12.9/11/13“M4, iPad Air 3/4/5/6/M2/M3, iPad mini 5/6

(1,985)
$14.22
FREE delivery Tue, Sep 9 on your first order
1K+ bought in past month
Loading...
Logitech G203 Wired Gaming Mouse, 8,000 DPI, Rainbow Optical Effect LIGHTSYNC RGB, 6 Programmable Buttons, On-Board Memory, Screen Mapping, PC/Mac Computer and Laptop Compatible - Black
Best Seller

Logitech G203 Wired Gaming Mouse, 8,000 DPI, Rainbow Optical Effect LIGHTSYNC RGB, 6 Programmable Buttons, On-Board Memory, Screen Mapping, PC/Mac Computer and Laptop Compatible - Black

(17,871)
$27.98$22.38
FREE delivery Tue, Oct 14 on your first order
500+ bought in past month
Loading...
Logitech G305 LIGHTSPEED Wireless Gaming Mouse, Hero 12K Sensor, 12,000 DPI, Lightweight, 6 Programmable Buttons, 250h Battery Life, On-Board Memory, PC/Mac - Black

Logitech G305 LIGHTSPEED Wireless Gaming Mouse, Hero 12K Sensor, 12,000 DPI, Lightweight, 6 Programmable Buttons, 250h Battery Life, On-Board Memory, PC/Mac - Black

(21,223)
$44.98
FREE delivery Tue, Oct 14
1K+ bought in past month
Loading...
Anker 332 USB-C Hub (5-in-1) with 4K HDMI Display, 5Gbps - and 2 5Gbps USB-A Data Ports and for MacBook Pro, MacBook Air, Dell XPS, Lenovo Thinkpad, HP Laptops and More

Anker 332 USB-C Hub (5-in-1) with 4K HDMI Display, 5Gbps - and 2 5Gbps USB-A Data Ports and for MacBook Pro, MacBook Air, Dell XPS, Lenovo Thinkpad, HP Laptops and More

(11,639)
$23.99
FREE delivery Sat, Jun 14 on your first order
1K+ bought in past month
Loading...
The Bible In A Year: A 52-Week Study Through God's Word, Spiral Bound Bible Study Guide Journal Notebook, A Beautiful Year Planner in the Bible for Women (A5)

The Bible In A Year: A 52-Week Study Through God's Word, Spiral Bound Bible Study Guide Journal Notebook, A Beautiful Year Planner in the Bible for Women (A5)

(1)
$23.99
FREE delivery Fri, Oct 10 on your first order
Loading...
Monster N-Lite 211 Wireless Earbuds, Bluetooth 6.0 Stereo Headphones with Noise-Cancelling Mic and LED Display, Built-in Mic for Clear Calls, Waterproof Design for Sports

Monster N-Lite 211 Wireless Earbuds, Bluetooth 6.0 Stereo Headphones with Noise-Cancelling Mic and LED Display, Built-in Mic for Clear Calls, Waterproof Design for Sports

(8)
$39.99
FREE delivery Tue, Nov 4
Loading...
Monster N-Lite 211 Wireless Earbuds, Bluetooth 6.0 Stereo Headphones with Powerful Bass, Built-in Noise-Cancelling Mic for Clear Calls, LED Display, 36H Playtime, IPX5 Waterproof Design for Sports

Monster N-Lite 211 Wireless Earbuds, Bluetooth 6.0 Stereo Headphones with Powerful Bass, Built-in Noise-Cancelling Mic for Clear Calls, LED Display, 36H Playtime, IPX5 Waterproof Design for Sports

(40)
$39.99
FREE delivery Thu, Nov 13