Closed tgwstyle closed 3 weeks ago
{ "name": "AwesomeProject_2", "version": "0.0.1", "private": true, "scripts": { "android": "react-native run-android", "ios": "react-native run-ios", "lint": "eslint .", "start": "react-native start", "test": "jest" }, "dependencies": { "@react-native-community/masked-view": "^0.1.11", "@react-navigation/bottom-tabs": "6.3.0", "@react-navigation/native": "6.1.6", "react": "18.3.1", "react-native": "0.75.4", "react-native-gesture-handler": "2.16.0", "react-native-reanimated": "^3.16.0", "react-native-safe-area-context": "4.5.1", "react-native-screens": "3.33.0" }, "devDependencies": { "@babel/core": "^7.20.0", "@babel/preset-env": "^7.20.0", "@babel/runtime": "^7.20.0", "@react-native/babel-preset": "0.75.4", "@react-native/eslint-config": "0.75.4", "@react-native/metro-config": "0.75.4", "@react-native/typescript-config": "0.75.4", "@types/react": "^18.2.6", "@types/react-test-renderer": "^18.0.0", "babel-jest": "^29.6.3", "eslint": "^8.19.0", "jest": "^29.6.3", "prettier": "2.8.8", "react-test-renderer": "18.3.1", "typescript": "5.0.4" }, "engines": { "node": ">=18" } }
删掉报错的ndk目录
这个问题我也碰到了,好像是gradle不能正常下载需要的ndk,那个报错的ndk目录实际是空的 自己去as里安装这个指定版本的ndk即可
使用@react-navigation/bottom-tabs实现底部导航时报错,报错截图如下:
各插件及版本如下:
安装插件之后,执行yarn android报错,
{ "name": "AwesomeProject_2", "version": "0.0.1", "private": true, "scripts": { "android": "react-native run-android", "ios": "react-native run-ios", "lint": "eslint .", "start": "react-native start", "test": "jest" }, "dependencies": { "@react-native-community/masked-view": "^0.1.11", "@react-navigation/bottom-tabs": "6.3.0", "@react-navigation/native": "6.1.6", "react": "18.3.1", "react-native": "0.75.4", "react-native-gesture-handler": "2.16.0", "react-native-reanimated": "^3.16.0", "react-native-safe-area-context": "4.5.1", "react-native-screens": "3.33.0" }, "devDependencies": { "@babel/core": "^7.20.0", "@babel/preset-env": "^7.20.0", "@babel/runtime": "^7.20.0", "@react-native/babel-preset": "0.75.4", "@react-native/eslint-config": "0.75.4", "@react-native/metro-config": "0.75.4", "@react-native/typescript-config": "0.75.4", "@types/react": "^18.2.6", "@types/react-test-renderer": "^18.0.0", "babel-jest": "^29.6.3", "eslint": "^8.19.0", "jest": "^29.6.3", "prettier": "2.8.8", "react-test-renderer": "18.3.1", "typescript": "5.0.4" }, "engines": { "node": ">=18" } }
预期结果: 期望实现结果似图下: