0.6.0 • Published 4 years ago

umi-preset-react-navigation v0.6.0

Weekly downloads
4
License
MIT
Repository
github
Last release
4 years ago

umi-preset-react-navigation

针对 react-navigationumi 插件集。

支持在 RN 应用中替换 umi 默认的 react-router

内置react-navigation 5.x 版本,需要 react-native 0.60.0 及以上版本(>=0.60.x)

了解如何使用umi开发 RN 应用,请移步至:umi-react-native

目录

安装

在 RN 工程根目录下,使用 yarn 安装umi-preset-react-navigation

yarn add umi-preset-react-navigation --dev

接下来,安装react-navigation的依赖:

  • react-native-reanimated
  • react-native-gesture-handler
  • react-native-screens
  • react-native-safe-area-context
  • @react-native-community/masked-view

根据你所使用的 RN 开发工具:

React Native CLI

使用yarn安装react-navigation的依赖:

yarn add react-native-reanimated react-native-gesture-handler react-native-screens react-native-safe-area-context @react-native-community/masked-view

RN 0.60.0 及以上版本有自动链接功能,Android 会自动搞定这些react-navigation的原生依赖,但对于iOS,待 yarn 安装完成后,还需要进到 ios 目录,使用 pod 安装:

cd ios && pod install

npm.io

注意:因为添加了原生依赖,需要执行:yarn iosyarn android重新编译和启动 iOS 和 Android 工程。

expo

使用expo安装react-navigation的依赖:

expo install react-native-gesture-handler react-native-reanimated react-native-screens react-native-safe-area-context @react-native-community/masked-view
0.6.0

4 years ago

0.6.0-alpha.3

4 years ago

0.6.0-alpha.1

4 years ago

0.6.0-alpha.0

4 years ago

0.5.0

4 years ago

0.5.1

4 years ago

0.4.0

4 years ago

0.3.4

4 years ago

0.3.2

4 years ago

0.3.0-alpha.0

4 years ago

0.2.0-alpha.6

4 years ago

0.2.0-alpha.5

4 years ago

0.2.0-alpha.4

4 years ago

0.2.0-alpha.2

4 years ago

0.2.0-alpha.1

4 years ago

0.2.0-alpha.0

4 years ago

0.1.0-alpha.3

4 years ago

0.1.0-alpha.2

4 years ago

0.1.0-alpha.1

4 years ago

0.1.0-alpha.0

4 years ago