是否可以将动画应用于react-router-native? [英] Is it possible to apply animation for react-router-native?

查看:156
本文介绍了是否可以将动画应用于react-router-native?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道这个问题听起来像是在征求建议,但这不应该在这里,但是我在搜索了很多要求之后发布了消息.

I know that this question sounds like asking for suggestion which should not be here, But I am posting after searching a lot for my requirement.

我正在使用react-router-native进行导航,这是非常明智的选择.但是在动画部分,它并不能提供最佳的用户体验. 官方文档似乎没有提供任何动画信息.

I am using react-router-native for navigation which is great functionality wise. But comes to the animation part, it doesn't give the best user experience. Official Documentation doesn't seem like providing any animation information.

即使在Google中,我也发现了一些文章(深入研究React Router v4动画过渡动画路线使用React Router的过渡)描述了用于导航的动画,但仅用于react.

Even in the google I found some articles(A shallow dive into React Router v4 Animated Transitions, Animating Route Transitions with React Router) describing about animation for navigation but only for react.

因此,有人可以让我知道有什么方法可以为react-router-native应用动画吗?

Hence, Could anybody let me know that is there any way to apply animation for react-router-native?

推荐答案

我认为您需要

I think you need react-router-native-animate-stackreact-router-native-animate-stack

yarn add react-router-native-animate-stack

默认情况下,这是可滑动的,您可以自定义过渡到下一页时的过渡.

This is by default swipeable and you can customize the transition when move to next page.

截屏视频

这是在博览会小吃上运行的包装示例

This is the package example running on expo snack

示例

这篇关于是否可以将动画应用于react-router-native?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆