compose-navigation-nav3
CommunityBuild process-death safe Nav3 navigation.
System Documentation
What problem does it solve?
compose-navigation-nav3 helps you implement Jetpack Compose Navigation 3 correctly so that navigation state, destination arguments, and ViewModel lifecycles behave safely—especially across recomposition and Android process death—while avoiding costly mistakes during Nav2→Nav3 migrations.
Core Features & Use Cases
- NavKey-driven typed destinations: enforce
NavKey+@Serializableon every route to enable back-stack restore after process death. - Hoisted back stack with
rememberNavBackStack: ensure process-death save/restore by managing the back stack as state rather than relying on Nav2-style controllers. - Required ViewModel decorators: use
rememberViewModelStoreNavEntryDecorator(and optionallyrememberSaveableStateHolderNavEntryDecorator) to prevent ViewModel leaks and preserve per-entry UI state. - SceneStrategy patterns for multi-pane and dialogs: wire
SinglePaneSceneStrategy,rememberListDetailSceneStrategy, andDialogSceneStrategy, with guidance for custom bottom-sheet navigation. - Nav2→Nav3 migration mapping: translate mental models and identify unsupported Nav2 features (deep links, nested graphs > 1 level, shared destinations across back stacks, string routes).
Quick Start
Use compose-navigation-nav3 when implementing Nav3 navigation by creating typed @Serializable NavKey destinations, initializing your back stack with rememberNavBackStack, and wiring NavDisplay with rememberViewModelStoreNavEntryDecorator() plus the appropriate SceneStrategy.
Dependency Matrix
Required Modules
None requiredComponents
💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: compose-navigation-nav3 Download link: https://github.com/santimattius/performance-compose-skills/archive/main.zip#compose-navigation-nav3 Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.