I was trying out Navigation architecture component and is now having difficulties in setting the title. How do I set the title programmatically and also how it works?
The API may have changed since the question was asked, but now you may indicate a reference to a string in your app resources in the navigation graph label.
This is pretty helpful if you want a static title for your fragments.