Implementing borders on Buttons
See original GitHub issueHey, thank you for making this really cool lib.
I added this to my project and started swapping out TouchableHighlight
and TouchableOpacity
for RectButton
, and noticed that borders weren’t rendering.
Looking at the example, it seems you have borders implemented in some places but not through styles attached to RectButton
’s.
The MainScreen uses FlatList’s ItemSeparatorComponent
to render an ItemSeparator
component , and the rows
/ “Table rows & buttons” example uses a “buttonDelimiter” View
in between RectButton
’s to represent a bottom border.
Is this the best (or only) way to implement borders?
There was a discussion in #59 and a PR #151 that seem to address issues with borderRadius
, but I did not see anything about the border
layout props we get in RN (borderWidth
, borderColor
). Does it have anything to do with the overflow: hidden
styles?
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:5 (4 by maintainers)
@pcooney10 I’m facing the issue of border not appearing on Android. It does work well on iOS though. style props like borderRadius works, but borderWidth, borderColor does not work on Android
Hey @osdnk, didn’t see your response until now.
I am sorry if my original question was wordy, but essentially I am asking if the
RectButton
component can be styled withborderBottomWidth: 1
,borderBottomColor: '#000'
, etc.When I said “swapping out TouchableHighlight and TouchableOpacity for RectButton”, I meant I was replacing instances of TouchableHighlight and TouchableOpacity with RectButton.