How to add top border to tab that is active using react native bottom tabs
You can make use of focused prop like this
<Tab.Screen
name="ScreenName"
component={Screen}
options={{
tabBarIcon: ({ color, focused }) => (
<View style={styles.individualTabWrapper}>
{
focused && <View style={styles.activeDot} />
}
<CustomIcon name={'home'} size={focused ? 27 : 25} color={color} />
</View>
),
tabBarLabel: ({ focused, color }) => (
<>
<Text style={[styles.label, { color: 'black'}]}>Home</Text>
</>
)
}}
/>