admin管理员组

文章数量:1295303

Is there a way to set the color of the headerBackTitle in the Stacknavigator?

navigationOptions: ({ navigation }) => ({
    ...
    headerBackTitle: "Back",
    }),
    ...

Depending on the background color the header has, the headerBackTitle is not readable.

Is there a way to set the color of the headerBackTitle in the Stacknavigator?

navigationOptions: ({ navigation }) => ({
    ...
    headerBackTitle: "Back",
    }),
    ...

Depending on the background color the header has, the headerBackTitle is not readable.

Share asked Sep 8, 2017 at 10:51 four-eyesfour-eyes 12.5k36 gold badges130 silver badges254 bronze badges
Add a ment  | 

2 Answers 2

Reset to default 7

I know this question was a long time ago but anyways, headerBackTitleStyle will change only the color, better use headerTintColor: '#FF0000' to change text and icon

You can use headerBackTitleStyle to style your back button.

navigationOptions: ({ navigation }) => ({
    ...
    headerBackTitle: "Back",
    headerBackTitleStyle: {
        color: 'pink'
    }
}),
...

本文标签: javascriptColor of headerBackTitle react navigationStack Overflow