Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/node.js/43.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript Heroku中部署React应用程序时出现ELIFECYCLE错误_Javascript_Node.js_Reactjs_Heroku - Fatal编程技术网

Javascript Heroku中部署React应用程序时出现ELIFECYCLE错误

Javascript Heroku中部署React应用程序时出现ELIFECYCLE错误,javascript,node.js,reactjs,heroku,Javascript,Node.js,Reactjs,Heroku,我尝试使用heroku cli在heroku中部署react应用程序,但出现以下错误: sh: 1: react-app-rewired: not found npm ERR! file sh npm ERR! code ELIFECYCLE npm ERR! errno ENOENT npm ERR! syscall spawn npm ERR! Test@1.7.0 start: `react-app-rewired start` npm ERR! spawn ENOENT npm ERR!

我尝试使用heroku cli在heroku中部署react应用程序,但出现以下错误:

sh: 1: react-app-rewired: not found
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! Test@1.7.0 start: `react-app-rewired start`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the Test@1.7.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /app/.npm/_logs/2019-11-05T06_11_59_280Z-debug.log
其他解决方案建议删除node_模块和package-lock.json,然后再次尝试执行npm安装,但似乎不起作用。我们还包括了我们正在使用的节点的版本

这是我的package.json

{
  "name": "Test",
  "version": "1.7.0",
  "private": true,
  "engines": {
    "node": "10.15.3"
  },
  "dependencies": {
    "@amcharts/amcharts3-react": "^3.1.0",
    "amcharts3": "^3.21.13",
    "antd": "^3.11.6",
    "antd-theme-webpack-plugin": "^1.1.6",
    "axios": "^0.18.0",
    "draftjs-to-html": "^0.8.4",
    "firebase": "5.3.1",
    "install": "^0.12.2",
    "instantsearch.css": "^7.1.0",
    "less": "2.7.3",
    "less-loader": "^4.1.0",
    "less-vars-to-js": "^1.2.1",
    "lodash": "^4.17.11",
    "moment": "^2.22.2",
    "nprogress": "^0.2.0",
    "prop-types": "^15.6.2",
    "react": "^16.8.6",
    "react-big-calendar": "^0.19.2",
    "react-bootstrap-sweetalert": "^4.4.1",
    "react-ckeditor-component": "^1.0.7",
    "react-color": "^2.14.1",
    "react-custom-scrollbars": "^4.2.1",
    "react-dnd": "^5.0.0",
    "react-dnd-html5-backend": "^5.0.1",
    "react-dom": "^16.8.6",
    "react-draft-wysiwyg": "^1.12.13",
    "react-flip-move": "^3.0.2",
    "react-google-maps": "^9.4.5",
    "react-hot-loader": "^4.6.3",
    "react-instantsearch": "^5.2.2",
    "react-instantsearch-dom": "^5.2.2",
    "react-intl": "^2.4.0",
    "react-notifications": "^1.4.3",
    "react-placeholder": "^3.0.1",
    "react-redux": "^5.0.7",
    "react-router-dom": "^4.3.1",
    "react-router-redux": "^5.0.0-alpha.9",
    "react-scripts": "^2.1.3",
    "react-simple-maps": "^0.12.1",
    "react-slick": "^0.23.1",
    "react-sortable-hoc": "^0.8.3",
    "react-star-rating-component": "^1.4.1",
    "react-stickies": "^0.0.16",
    "recharts": "^1.0.1",
    "redux": "^4.0.0",
    "redux-saga": "^0.16.0",
    "redux-thunk": "^2.3.0",
    "rheostat": "^3.0.1",
    "slick-carousel": "^1.8.1",
    "url-search-params": "^1.1.0",
    "victory": "^0.27.2"
  },
  "scripts": {
    "start": "react-app-rewired start",
    "build": "react-app-rewired build",
    "test": "react-app-rewired --env=jsdom"
  },
  "devDependencies": {
    "add": "^2.0.6",
    "babel-plugin-import": "^1.8.0",
    "customize-cra": "^0.2.10",
    "react-app-rewired": "^2.0.2"
  },

真希望你能帮忙。非常感谢你

请验证是否存在node_modules/react app rewired目录,以及node_modules/.bin/react app rewired脚本是否存在?是。我有。