【发布时间】:2021-04-16 08:30:54
【问题描述】:
所以我正在使用 React Native 开发应用程序并尝试通过 AppStoreConnect 将应用程序上传到 TestFlight。每次我上传我都会收到一封来自苹果的电子邮件:
ITMS-90809:不推荐使用的 API - 不再接受使用 UIWebView 的新应用。相反,使用 WKWebView 来提高安全性和可靠性
是的,我看过 Stackoverflow 上的类似帖子。这是我尝试过的事情。
1。我在node_modules 和Pods 文件夹上都运行了grep -r UIWebView,我得到的唯一匹配是评论标签。
对于节点模块:
node_modules/create-react-context/node_modules/fbjs/lib/UserAgent.js.flow: * - UIWebView
node_modules/create-react-context/node_modules/fbjs/lib/UserAgent.js: * - UIWebView
node_modules/fbjs/lib/UserAgent.js.flow: * - UIWebView
node_modules/fbjs/lib/UserAgent.js: * - UIWebView
node_modules/jsc-android/dist/include/JSContextPrivate.h:/*! @abstract The delegate the context will use when trying to load a module. Note, this delegate will be ignored for contexts returned by UIWebView. */
node_modules/react-native-gesture-handler/node_modules/fbjs/lib/UserAgent.js.flow: * - UIWebView
node_modules/react-native-gesture-handler/node_modules/fbjs/lib/UserAgent.js: * - UIWebView
node_modules/react-native-keyboard-manager/ios/IQKeyboardManager/IQKeyboardManager.m: // We are unable to get textField object while keyboard showing on UIWebView's textField. (Bug ID: #11)
node_modules/react-native-keyboard-manager/ios/IQKeyboardManager/IQKeyboardManager.m: //Commented due to #56. Added all the conditions below to handle UIWebView's textFields. (Bug ID: #56)
node_modules/react-native-keyboard-manager/ios/IQKeyboardManager/IQKeyboardManager.m: // We are unable to get textField object while keyboard showing on UIWebView's textField. (Bug ID: #11)
node_modules/ua-parser-js/test/browser-test.json: "ua" : "Mozilla/5.0 (iPhone; CPU iPhone OS 10_0_2 like Mac OS X) AppleWebKit/602.1.50 (KHTML, like Gecko) Mobile/14A456 QQ/6.5.3.410 V1_IPH_SQ_6.5.3_1_APP_A Pixel/1080 Core/UIWebView NetType/WIFI Mem/26",
对于 Pods 文件夹:
./Pods/IQKeyboardManager/IQKeyboardManager/IQKeyboardManager.m: // We are unable to get textField object while keyboard showing on UIWebView's textField. (Bug ID: #11)
./Pods/IQKeyboardManager/IQKeyboardManager/IQKeyboardManager.m: //Commented due to #56. Added all the conditions below to handle UIWebView's textFields. (Bug ID: #56)
./Pods/IQKeyboardManager/IQKeyboardManager/IQKeyboardManager.m: // We are unable to get textField object while keyboard showing on UIWebView's textField. (Bug ID: #11)
2。我还更新到最新的 react-native 版本,这是我的 package.json 的样子:
"dependencies": {
"react-native-signature-capture": "^0.4.10",
"@react-native-community/masked-view": "^0.1.10",
"@react-navigation/native": "^5.8.10",
"@react-navigation/stack": "^5.12.8",
"axios": "^0.21.1",
"dayjs": "^1.8.17",
"dot-object": "^1.9.0",
"lodash.debounce": "^4.0.8",
"lodash.get": "^4.4.2",
"react": "16.8.6",
"react-native": "^0.63.4",
"react-native-date-picker": "^3.2.7",
"react-native-elements": "^3.1.0",
"react-native-gesture-handler": "^1.9.0",
"react-native-keyboard-manager": "^4.0.13-17",
"react-native-modal-selector": "^2.0.3",
"react-native-numeric-input": "^1.8.3",
"react-native-paper": "^2.16.0",
"react-native-pdf": "^5.1.7",
"react-native-picker-select": "^8.0.4",
"react-native-reanimated": "^1.13.2",
"react-native-safe-area-context": "^3.1.9",
"react-native-screens": "^2.16.1",
"react-native-step-indicator": "^1.0.3",
"react-native-tailwind": "^1.0.10",
"react-native-vector-icons": "^6.6.0",
"rn-fetch-blob": "^0.12.0",
"sanitize-html": "^1.22.1",
"yup": "^0.27.0"
},
"devDependencies": {
"@babel/core": "^7.12.10",
"@babel/runtime": "^7.12.5",
"@react-native-community/eslint-config": "^0.0.5",
"babel-jest": "^24.9.0",
"babel-plugin-module-resolver": "^3.2.0",
"eslint": "^6.7.1",
"jest": "^24.9.0",
"metro-react-native-babel-preset": "^0.56.3",
"react-test-renderer": "16.8.6"
},
如果有人有想法或可以指出正确的方向,在此先感谢您。
【问题讨论】:
-
您是否尝试在项目的根文件夹中运行该 grep 命令?我对 React Native 不是很熟悉,但我遇到了类似的问题,我发现在我的项目其他地方的静态库中使用了
UIWebView。 -
@Jobert 是的,我已经尝试过了,它的结果与 node_modules 和 Pods 文件夹上的
grep -r UIWebView相同。我注意到 XCODE 上有Frameworks, Libraries and Embedded Content部分,并试图弄清楚如何检查他们是否可能正在使用 UIWebView。
标签: javascript ios react-native app-store-connect testflight