:\blockchain\truffle\demo\mortgage-blockchain-demo>truffle serve erving static assets in .\build on port 8080... ebuilding... :\Users\Mabel\AppData\Roaming\npm\node_modules\truffle\build\cli.bundled.js:220 48 return (new fsevents(path)).on('fsevent', callback).start(); ^ ypeError: fsevents is not a constructor at createFSEventsInstance (C:\Users\Mabel\AppData\Roaming\npm\node_modules\t uffle\build\cli.bundled.js:220548:11) at setFSEventsListener (C:\Users\Mabel\AppData\Roaming\npm\node_modules\truf le\build\cli.bundled.js:220602:16) at FSWatcher.FsEventsHandler._watchWithFsEvents (C:\Users\Mabel\AppData\Roam ng\npm\node_modules\truffle\build\cli.bundled.js:220766:16) at FSWatcher.<anonymous> (C:\Users\Mabel\AppData\Roaming\npm\node_modules\tr ffle\build\cli.bundled.js:220900:25) at LOOP (fs.js:1758:14) at _combinedTickCallback (internal/process/next_tick.js:67:7) at process._tickCallback (internal/process/next_tick.js:98:9)
请帮我解决这个问题。我在Windows 7机器上运行。
试图做以太坊松露设置。
不使用时禁用FsEvents
:
脚步:
truffle compile && truffle build && truffle migrate && truffle serve
只需在//Users/**abc/projectFolder/node_modules/chokidar/lib/fsevents-handler.js中删除/删除以下代码
function createFSEventsInstance(path,callback){
// return(new fsevents(path))。on('fsevent',callback).start();
}
现场:
using create-react-app
/Users/**abc/projectFolder/node_modules/chokidar/lib/fsevents-handler.js
解:
Temporarily //return (new fsevents(path)).on('fsevent', callback).start();