wechat-bot icon indicating copy to clipboard operation
wechat-bot copied to clipboard

npm run dev issue

Open hhy885 opened this issue 2 years ago • 2 comments

~/wechatbot/wechat-bot$ npm run dev

[email protected] dev /home/tz/wechatbot/wechat-bot node ./index.js

/home/tz/wechatbot/wechat-bot/index.js:1 import "./src/wechaty/index.js"; ^^^^^^^^^^^^^^^^^^^^^^^^

SyntaxError: Unexpected string at Module._compile (internal/modules/cjs/loader.js:723:23) at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10) at Module.load (internal/modules/cjs/loader.js:653:32) at tryModuleLoad (internal/modules/cjs/loader.js:593:12) at Function.Module._load (internal/modules/cjs/loader.js:585:3) at Function.Module.runMain (internal/modules/cjs/loader.js:831:12) at startup (internal/bootstrap/node.js:283:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! [email protected] dev: node ./index.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the [email protected] dev script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. 2022-12-12T22_46_07_481Z-debug.log

npm ERR! A complete log of this run can be found in: npm ERR! /home/tz/.npm/_logs/2022-12-12T22_46_07_481Z-debug.log

==>

Resolved by updating to the latest version nodejs!!

hhy885 avatar Dec 12 '22 22:12 hhy885

Resolved by updating to the latest version nodejs!!

hhy885 avatar Dec 12 '22 23:12 hhy885

先参考这个方案。 https://github.com/wangrongding/wechat-bot/issues/54#issuecomment-1347743629

wangrongding avatar Dec 13 '22 05:12 wangrongding