Skip to content

Commit 381ecc3

Browse files
authored
Merge pull request #101 from cedricboidin/version0.62
Version0.62
2 parents e446df5 + 10abecc commit 381ecc3

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/index.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,8 @@ export default class Swipeable extends PureComponent {
145145
swipeReleaseAnimationConfig: {
146146
toValue: {x: 0, y: 0},
147147
duration: 250,
148-
easing: Easing.elastic(0.5)
148+
easing: Easing.elastic(0.5),
149+
useNativeDriver: false
149150
},
150151

151152
// misc
@@ -166,7 +167,7 @@ export default class Swipeable extends PureComponent {
166167
rightButtonsOpen: false
167168
};
168169

169-
UNSAFE_componentWillMount() {
170+
componentDidMount() {
170171
const {onPanAnimatedValueRef, onRef} = this.props;
171172

172173
onRef(this);
@@ -203,8 +204,8 @@ export default class Swipeable extends PureComponent {
203204

204205
_handlePan = Animated.event([null, {
205206
dx: this.state.pan.x,
206-
dy: this.state.pan.y
207-
}]);
207+
dy: this.state.pan.y,
208+
}], {useNativeDriver: false});
208209

209210
_handleMoveShouldSetPanResponder = (event, gestureState) => (
210211
Math.abs(gestureState.dx) > this.props.swipeStartMinDistance

0 commit comments

Comments
 (0)