Skip to content

Commit

Permalink
Merge pull request #1 from RodolfoGS/fix-useNativeDriver
Browse files Browse the repository at this point in the history
Fix: useNativeDriver was not specified
  • Loading branch information
RodolfoGS authored Jul 2, 2022
2 parents 1873597 + 7341dfe commit abbc146
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions lib/ActionSheetCustom.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,16 @@ class ActionSheet extends React.Component {
Animated.timing(this.state.sheetAnim, {
toValue: 0,
duration: 250,
easing: Easing.out(Easing.ease)
easing: Easing.out(Easing.ease),
useNativeDriver: true,
}).start()
}

_hideSheet (callback) {
Animated.timing(this.state.sheetAnim, {
toValue: this.translateY,
duration: 200
duration: 200,
useNativeDriver: true,
}).start(callback)
}

Expand Down Expand Up @@ -181,7 +183,7 @@ class ActionSheet extends React.Component {
const { visible, sheetAnim } = this.state
return (
<Modal visible={visible}
animationType='none'
animationType="fade"
transparent
onRequestClose={this._cancel}
>
Expand Down

0 comments on commit abbc146

Please sign in to comment.