【问题标题】:React/RCTConvert.h file not found with ReactNativeNavigation ver3使用 ReactNativeNavigation ver3 找不到 React/RCTConvert.h 文件
【发布时间】:2019-07-28 03:02:39
【问题描述】:

我正在为移动应用开发以下技术。

react-native: v0.60.0
react-native-navigation: 3.0.0-alpha.2

我为 iOS 构建了这个应用程序,然后在 ReactNativeNavigation 代码中出现以下错误消息。

React/RCTConvert.h file not found

错误文件是Pods/Development Pods/ReactNativeNavigation/RNNOptions.h,这就是它的内容。

#import <UIKit/UIKit.h>
#import <React/RCTConvert.h>
#import "BoolParser.h"
#import "TextParser.h"
#import "NumberParser.h"
#import "DictionaryParser.h"
#import "ColorParser.h"
#import "ImageParser.h"
#import "IntNumberParser.h"
#import "DoubleParser.h"

@interface RNNOptions : NSObject

- (instancetype)initWithDict:(NSDictionary*)dict;

- (RNNOptions *)overrideOptions:(RNNOptions *)otherOptions;
- (RNNOptions *)mergeOptions:(RNNOptions *)otherOptions;
- (RNNOptions *)mergeInOptions:(RNNOptions *)otherOptions;

- (RNNOptions *)withDefault:(RNNOptions *)defaultOptions;

@end

我已经试过了,

但效果不好,所以我又尝试了这些。

  • pod 'ReactNativeNavigation', :path =&gt; '../node_modules/react-native-navigation' 插入ios/Podfile
  • ios目录中运行react-native link react-native-navigationpod install

  • 在 Xcode 中清理并重建项目。

【问题讨论】:

    标签: react-native react-native-navigation


    【解决方案1】:

    使用 react native 0.60+,您无需手动链接 react native 导航。

    只需运行 react-native link react-native-navigationcd ios; pod install

    更多信息请查看issue

    【讨论】:

    • 反应原生 0.59 怎么样
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2022-01-24
    • 1970-01-01
    • 1970-01-01
    • 2019-07-16
    • 2018-03-10
    • 2022-01-19
    • 2021-04-10
    相关资源
    最近更新 更多