我试图运行我的应用程序,但是突然我出现了这个错误。
警告软件包@ babel / runtime被忽略,因为它包含无效的配置。原因:找不到模块'@babel \ runtime \ package.json'
但是我在package.json中有@babel \ runtime 这是package.json的文件
{
"name": "rasa",
"version": "0.0.1",
"private": true,
"scripts": {
"android": "react-native run-android",
"ios": "react-native run-ios",
"start": "react-native start",
"test": "jest",
"lint": "eslint ."
},
"dependencies": {
"deprecated-react-native-listview": "0.0.6",
"react": "16.11.0",
"react-native": "0.62.2",
"react-native-responsive-dimensions": "^3.1.1"
},
"devDependencies": {
"@babel/core": "^7.6.2",
"@babel/runtime": "^7.6.2",
"@react-native-community/eslint-config": "^0.0.5",
"babel-jest": "^24.9.0",
"eslint": "^6.5.1",
"jest": "^24.9.0",
"metro-react-native-babel-preset": "^0.58.0",
"react-test-renderer": "16.11.0"
},
"jest": {
"preset": "react-native"
}
}
我该如何解决它,我不想再次初始化我的项目,反正有解决此问题的方法吗?
答案 0 :(得分:3)
也许可以在命令行中尝试npm install
并再次运行。