Javascript 如何排除webpack故障;摩登派青年

Javascript 如何排除webpack故障;摩登派青年,javascript,reactjs,npm,ccxt,Javascript,Reactjs,Npm,Ccxt,我正在使用React,刚刚添加了这个模块,ccxt。在添加模块之前,一切正常。模块安装良好。后来,我在脚本中添加了这一行: const-ccxt=require('ccxt') 然后,当我发出npm start时,它会抛出一个错误: [WARN] No ENV file found [OKAY] Wrapping display Output to 78 Columns 16:29:02 backend.1 | info: Starting app... 16:29:03 frontend.

我正在使用React,刚刚添加了这个模块,ccxt。在添加模块之前,一切正常。模块安装良好。后来,我在脚本中添加了这一行:

const-ccxt=require('ccxt')

然后,当我发出
npm start
时,它会抛出一个错误:

[WARN] No ENV file found
[OKAY] Wrapping display Output to 78 Columns
16:29:02 backend.1  |  info: Starting app...
16:29:03 frontend.1 |  events.js:167
16:29:03 frontend.1 |        throw er; // Unhandled 'error' event
16:29:03 frontend.1 |        ^
16:29:03 frontend.1 |  Error: listen EADDRINUSE 127.0.0.1:8080
16:29:03 frontend.1 |      at Server.setupListenHandle [as _listen2] (net.js:1330:14)
16:29:03 frontend.1 |      at listenInCluster (net.js:1378:12)
16:29:03 frontend.1 |      at GetAddrInfoReqWrap.doListen [as callback] (net.js:1491:7)
16:29:03 frontend.1 |      at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:55:10)
16:29:03 frontend.1 |  Emitted 'error' event at:
16:29:03 frontend.1 |      at emitErrorNT (net.js:1357:8)
16:29:03 frontend.1 |      at process._tickCallback (internal/process/next_tick.js:63:19)
[DONE] Killing all processes with signal  null
internal/util.js:232
  throw new ERR_UNKNOWN_SIGNAL(signal);
  ^

TypeError [ERR_UNKNOWN_SIGNAL]: Unknown signal: null
    at convertToValidSignal (internal/util.js:232:9)
    at ChildProcess.kill (internal/child_process.js:411:5)
    at EventEmitter.<anonymous> (/home/marcus/development/nodestuff/crypto-crawler/node_modules/foreman/lib/proc.js:49:11)
    at EventEmitter.emit (events.js:187:15)
    at ChildProcess.<anonymous> (/home/marcus/development/nodestuff/crypto-crawler/node_modules/foreman/lib/proc.js:45:13)
    at ChildProcess.emit (events.js:182:13)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:235:12)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sails-react-webpack@0.2.0 start: `nf start --wrap`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the sails-react-webpack@0.2.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!     /home/marcus/.npm/_logs/2018-06-03T21_29_03_091Z-debug.log

有什么建议告诉我这是什么,或者你可以如何解决这个问题吗?

错误
错误:听着,EADDRINUSE 127.0.0.1:8080
似乎表明你试图在端口8080上运行两个进程

这里没有足够的关于您的开发环境/应用程序体系结构的信息来告诉您具体要做什么,但听起来您需要配置应用程序服务器或cctx以使用不同的端口。我猜在cctx中默认使用端口8080

尝试在应用程序的代码库中搜索
8080
,然后将其更改为其他内容。或者在cctx文档中查找配置选项,以指定要在其上运行的端口

此外,运行
lsof-i | grep8080
,查看您的机器上是否有其他进程使用端口8080

希望这有帮助,祝你好运

clean-webpack-plugin: /home/marcus/development/nodestuff/crypto-crawler/public/dist has been removed.
ModuleParseError: Module parse failed: /home/marcus/development/nodestuff/crypto-crawler/node_modules/ccxt/js/allcoin.js Unexpected token (60:10)
You may need an appropriate loader to handle this file type.