use*_*009 1 react-native react-animated
如何删除应用于 Animated.timing 函数的默认缓动 (easeInOut)?由于某种原因,设置ease: Easing.linear不会删除默认的 escapeInOut 计时。
Animated.timing(this.state.positionX, {
toValue: 1,
duration:1000,
ease: Easing.linear,
useNativeDriver: true,
}),
Run Code Online (Sandbox Code Playgroud)
您的配置对象应该读取easingnot ease。
Animated.timing(this.state.positionX, {
toValue: 1,
duration: 1000,
easing: Easing.linear,
useNativeDriver: true
});
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
2211 次 |
| 最近记录: |