Type safe, multi-module best practices with Navigation Compose
summary
Five concrete practices for scaling Navigation Compose across modules: define screens by state in / events out, split each screen into a NavGraphBuilder extension method that houses routes and argument handling, expose a minimal NavController extension per destination for runtime-checked type safety, and group screens into nested graphs with internal visibility to hide implementation. Also shows how to keep Kotlin Multiplatform-ready UI separate and recompose graphs at module boundaries; sample app and docs live in Android Github.
AI-written summary · about
chapters (5)
- 0:00Intro
- 0:40Define your screen
- 1:15Split up your navigation graph
- 2:30Build out only the public API surface
- 4:56Use your module structure
related talks
33mBreaking the Rules: Dynamic Navigation in Modularized Apps
30mBreaking the Rules: Dynamic Navigation in Modularized Apps
02mJetpack Compose Navigation: Beyond The Basics
28mNavigation in a Multiplatform World
41mNav2, Nav3… Or Roll Your Own? — Building to Understand Nav3’s Design Intent
14mNavigation Compose on every screen size
46mExploring Navigation Libraries for Compose
42mComposing your navigation: charting your route in the Jetpack ecosystem
