react-native - 如何检查项目的 native 版本?

标签 react-native

我正在编写一个 react-native 组件并使用事件,但是当发送事件是 bridge.eventDispatcher.. 时,我的 native 模块没有建立在旧版本的 react 上。

那么有没有办法检查版本以在 react 和 react-native 模块实现之间切换?
谢谢。

最佳答案

如果您键入 react-native --version在项目中,它会告诉您安装的版本(使用 react-native-cli v. 2.0.1 测试)。

关于react-native - 如何检查项目的 native 版本?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40071314/

相关文章:

javascript - 如何在 react native android中获取响应 header ?

javascript - React JS slider 滞后

react-native - react native watchmanResponse无法解析root

react-native - 如何在 React Navigation 5 的选项卡导航中传递空屏幕

javascript - React 状态从一个组件不一致地传递到下一个组件

react-native - 在不使用 Modal 的情况下使用 Navigator 以透明方式响应 Native Modal

react-native - React 导航打开 openDrawer() 不起作用

reactjs - 当状态第一次更新时,componentWillReceiveProps 不会触发

reactjs - react native : Under what circumstances do you have to manually add dependencies of your dependencies?

react-native - ComponentDidMount 触发两次