ReactNative?
1.#import <jschelpers/JavaScriptCore.h> file not exist
解決辦法:
在pods subspecs里面添加'BatchedBridge'
pod 'React', :path => './node_modules/react-native', :subspecs => [
'Core',
'RCTText',
'RCTNetwork',
'RCTWebSocket', # 這個模塊是用于調試功能的
'BatchedBridge',# 加上這個
# 在這里繼續(xù)添加你所需要的模塊
]
2.unable to resolve module 'react-navigation' from ....
解決方法:在package.json 的"dependencies"加入"react-navigation":"git+https://github.com/react-community/react-navigation.git#7edd9a7"
如下:
"dependencies": {
"react": "16.0.0-alpha.12",
"react-native": "0.45.1",
"react-navigation":"git+https://github.com/react-community/react-navigation.git#7edd9a7"
},
然后執(zhí)行安裝命令
yarn add react-navigation或者是npm install --save react-navigation
執(zhí)行后的"dependencies"如下:
"dependencies": {
"react": "16.0.0-alpha.12",
"react-native": "0.45.1",
"react-navigation": "^1.0.0-beta.11"
},
如果集成在現(xiàn)有工程里 還需要pod install