-
-
Save raamcosta/ffef2c3830d244533949da7f66f42cda to your computer and use it in GitHub Desktop.
Destination Extension example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@get:StringRes | |
val Destination.title get(): Int { | |
return when (this) { | |
ProfileScreenDestination -> R.string.profile_screen | |
LoginScreenDestination -> R.string.pogin_screen | |
MainFeedScreenDestination -> R.string.main_feed_screen | |
SearchScreenDestination -> R.string.search_screen | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment