RN运行ios报错No matching function for call to 'RCTBridgeModuleNameForClass'
xcode更新12.5后,ios运行报错No matching function for call to 'RCTBridgeModuleNameForClass'
解决方法:
在ios/Podfile文件中加入如下代码:
post_install do |installer|
## 以下 Fix for XCode 12.5
find_and_replace(
"../node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm",
"_initializeModules:(NSArray<id<RCTBridgeModule>> *)modules",
"_initializeModules:(NSArray<Class> *)modules") find_and_replace(
"../node_modules/react-native/ReactCommon/turbomodule/core/platform/ios/RCTTurboModuleManager.mm",
"RCTBridgeModuleNameForClass(strongModule))",
"RCTBridgeModuleNameForClass(Class(strongModule)))"
)
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '9.0'
end
end
end def find_and_replace(dir, findstr, replacestr)
Dir[dir].each do |name|
text = File.read(name)
replace = text.gsub(findstr,replacestr)
if text != replace
puts "Fix: " + name
File.open(name, "w") { |file| file.puts replace }
STDOUT.flush
end
end
Dir[dir + '*/'].each(&method(:find_and_replace))
end
End--------------------------
每腐烂一颗橘子 这个世界上就会多一个月球
RN运行ios报错No matching function for call to 'RCTBridgeModuleNameForClass'的更多相关文章
- VS2013运行C++报错:This function or variable may be unsafe. Consider using fopen_s instead.
在vs2013中运行时发生的关于方法调用的不安全错误. 1.更换方法,但是有些方法更改后参数不变,所以可能比较麻烦. 2.添加一条预处理器定义: 点击项目——>属性——>c/c++——&g ...
- 运行 puppeteer 报错 chrome: error while loading shared libraries: libpangocairo-1.0.so.0: cannot open shared object file: No such file or directory
运行 puppeteer 报错 chrome: error while loading shared libraries: libpangocairo-1.0.so.0: cannot open sh ...
- ios 报错记录
1. 运行xcode 报错:unterminated conditional directive #ifdef 缺少对应的#endif 在结尾加上就好了 2.iOS添加非(c,c++)文件引发的&qu ...
- linux下, 再次遇到使用thinkphp的模板标签时,报错used undefined function \Think\Template\simplexml_load_string() 是因为没有安装 php-xml包
linux下, 使用thinkphp的模板标签,如 eq, gt, volist defined, present , empty等 标签时, 报错: used undefined function ...
- 在ios7真机上和iOS6模拟器上运行是好的,而在iOS6真机上运行却报错
在ios7真机上和iOS6模拟器上运行是好的,而在iOS6真机上运行却报错 解决方法: 或是都设置为yes.. Build Active Architecture Only的意思是只生成适应的指令集
- 运行yum报错Error: Cannot retrieve metalink for reposit
http://www.netpc.com.cn/593.html 运行yum报错Error: Cannot retrieve metalink for reposit 今天给Centos通过rpm - ...
- 转:运行yum报错Error: Cannot retrieve metalink for reposit
http://www.netpc.com.cn/593.html 运行yum报错Error: Cannot retrieve metalink for repository: epel. Please ...
- iOS报错:linker command failed with exit code 1 (use -v to see invocation) 问题解决方式之一
百度库原版本:3.2.1 更新为:4.2.0,两个库相隔2年时间: 问题i: 更新CocoaPods的同时更新了百度地图库的版本,运行程序报错: linker command failed with ...
- 新建SpringBoot项目运行页面报错Whitelabel Error Page This application has no explicit mapping for /error, so yo
新建SpringBoot项目运行页面报错Whitelabel Error Page This application has no explicit mapping for /error, so yo ...
- 安装了nodejs后在命令行运行npm报错
安装了nodejs后在命令行运行npm报错:Error: Cannot find module 'internal/util/types' 解决方法:删除目录“C:\Users\mengxiaobo\ ...
随机推荐
- [转帖]Guanaco, Llama, Vicuña, Alpaca该怎么区别
https://zhuanlan.zhihu.com/p/106262896 在智利和秘鲁高原区经常会遇到的一种动物让人十分挠头,学术点称呼就是骆驼科其中一个族群--羊驼属和骆马属.头疼在于,分不清楚 ...
- [转帖]Nginx Ingress 高并发实践
概述 Nginx Ingress Controller 基于 Nginx 实现了 Kubernetes Ingress API,Nginx 是公认的高性能网关,但如果不对其进行一些参数调优,就不能充分 ...
- [转帖]如何理解 iowait
Linux中,%iowait 过高可能是个问题,严重的时候,它能使服务停止, 但问题是,多高才算高? 什么时候应该担心呢? 本文将讨论 iowait 的含义.相关的统计数据.原理以及 iowait的瓶 ...
- Docker镜像的基本操作总结
摘要 容器化是上个十年比较火的技术. 现在看起来在进行总计有点晚了. 不过linux是三十年前的,我依旧没有总结好 道理是一样的. 技术不在于新旧, 重要的是学习到原理. Docker的重要概念 Re ...
- 责任链和策略设计模式-基于Java编程语言
作者:京东物流 钟磊 1 前言 最近在梳理接口逻辑的时候发现,代码中使用的策略和责任链设计模式给我留下了非常深刻的印象.一个业务逻辑流程通常非常适合使用责任链和策略设计模式来实现,因为一个业务需求通常 ...
- Vue3中shallowReactive和shallowRef对数据进行非深度监听
1.Vue3 中 ref 和 reactive 都是深度监听 默认情况下, 无论是通过 ref 还是 reactive 都是深度监听. 深度监听存在的问题: 如果数据量比较大,非常消耗性能. 有些时候 ...
- Typescript中存取器getters和setters的使用
1.存取器 存取器可以让我们可以有效的控制对,对象中的中的成员的访问. 可以通过getters和setters来进行操作 在typescript中分别对应 get 和 set 2.如何解决报错 typ ...
- 配置elementuI菜单
:unique-opened="true" 只保留一个菜单 :router="true"开启路由标识 index="users" 是标识 它 ...
- cookie的设置读取
<script> // 设置cookie值哈 let username = '我是cookie' document.cookie = "name=" + usernam ...
- miniIO系列文章03---abpvext中集成
在Abp商业版本中已经提供了文件管理模块的,免费版本是没有的,本文将介绍如何使用Minio打造一个自己的文件管理模块. 在项目开始之前,需要先安装一个Minio服务,可以在本地pc或云主机中安装,具体 ...