why is action my action bar showing the title as f...
# android
m
why is action my action bar showing the title as fragment name? for example if I'm in HomeFragment, the action bar title is HomeFragment etc
a
If you are using navigation component that is the default behavior. The title in the graph is your toolbar title
m
so what's the workaround to get myself out on this?
a
Either set to empty string if you don't want any title or change to whatever you want including a variable value
m
Thank you. changed the fragment's label on
navigation.xml
solves this
note: the action bar's title follows the application name after removing the fragment's label
thank you once again @Anastasia Finogenova
a
No problem 😊
a
Change title (Add label in your
fragment
) form
Navigation
graph .