sharedViewModel

Retrieves or creates a shared ViewModel of type T associated with the navigation graph route.

Return

The shared ViewModel of type T.

Parameters

navController

The navigation controller for handling navigation events.