Skip to content

Commit 73dd71c

Browse files
committed
fix forwarding ref of ThouchableOpacity
1 parent b9135b1 commit 73dd71c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/components/touchableOpacity/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ class TouchableOpacity extends PureComponent {
9090
}
9191

9292
render() {
93-
const {style, modifiers, ...others} = this.props;
93+
const {style, modifiers, forwardedRef, ...others} = this.props;
9494
const {borderRadius, paddings, margins, alignments, flexStyle} = modifiers;
9595

9696
return (
@@ -110,7 +110,7 @@ class TouchableOpacity extends PureComponent {
110110
style,
111111
this.activeBackgroundStyle
112112
]}
113-
ref={this.setRef}
113+
ref={forwardedRef}
114114
/>
115115
);
116116
}

0 commit comments

Comments
 (0)