-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
使用forever启动报错 #6
Comments
ts-node 没安装成功嘛,安装的 typescript 是哪个版本的,会不会版本太低什么的,看报错时说没有高于2.7版本的 ts
… 在 2020年6月15日,下午4:15,lcnwys ***@***.***> 写道:
import createError = require('http-errors');
^^^^^^
SyntaxError: Unexpected token import
at createScript (vm.js:80:10)
at Object.runInThisContext (vm.js:139:10)
at Module._compile (module.js:616:28)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
at Function.Module.runMain (module.js:693:10)
at startup (bootstrap_node.js:188:16)
at bootstrap_node.js:609:3
error: Forever detected script exited with code: 1
网易云项目可以使用forever启动,但是migu的不行,我看migu是app.ts,我在全局安装ts-node的时候报错无法安装,是不是这个原因,我已经先安装了 typescript 但是一直提示我 `-- UNMET PEER DEPENDENCY typescript@>=2.7
npm WARN ***@***.*** requires a peer of typescript@>=2.7 but none was installed.
没安装上ts-node,在网上也找不到解决办法,大神知道怎么解决么
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub <#6>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AGFNGP5ICL64OK3FQB7YDIDRWXKAVANCNFSM4N55Z4GQ>.
|
我用npm全局安装的typescript 显示版本3.5 |
再全局安装一下 tslint 试试呢
… 在 2020年6月15日,下午4:25,lcnwys ***@***.***> 写道:
我用npm全局安装的typescript 显示版本3.5
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#6 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AGFNGPZYDGNUBEK6UW7GJPDRWXLGZANCNFSM4N55Z4GQ>.
|
tsc -v 都是正常的咯?我也不太清楚具体是为什么了,因为我也没怎么写过 ts 其实,还有一个 js 分支的,但是可能有些地方比较落后了,我也懒得同步更新了。。
… 在 2020年6月15日,下午5:10,lcnwys ***@***.***> 写道:
也是提示没有typescript 我卸载了typescript重新安装也还是不行,我查了库都有,好奇怪
<https://user-images.githubusercontent.com/40192017/84639305-c5308500-af2a-11ea-8d12-3b2e1e0db337.jpeg>
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#6 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AGFNGP5XQHSGYJCUZUZI5LDRWXQP3ANCNFSM4N55Z4GQ>.
|
找到一个解决办法 |
emmm,所以是启动器的关系?我倒是没用过 forever 一直都是用pm2 |
我今天也改用 pm2 start npm --name test -- start 这样用npm启动就没问题啦 |
我很想知道为什么搜索Mijito查不到,却蹦出来迷迭香 >.< |
这个我是用的移动web端的接口,我访问了一下,他们确实搜不出来的。主要是pc上服务端渲染,没有借口,最多只能爬虫
… 在 2020年6月19日,上午12:18,lcnwys ***@***.***> 写道:
我很想知道为什么搜索Mijito查不到,却蹦出来迷迭香
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#6 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AGFNGP4G5F47ZNFAQMB6OMTRXI45LANCNFSM4N55Z4GQ>.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
import createError = require('http-errors');
^^^^^^
SyntaxError: Unexpected token import
at createScript (vm.js:80:10)
at Object.runInThisContext (vm.js:139:10)
at Module._compile (module.js:616:28)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
at Function.Module.runMain (module.js:693:10)
at startup (bootstrap_node.js:188:16)
at bootstrap_node.js:609:3
error: Forever detected script exited with code: 1
网易云项目可以使用forever启动,但是migu的不行,我看migu是app.ts,我在全局安装ts-node的时候报错无法安装,是不是这个原因,我已经先安装了 typescript 但是一直提示我 `-- UNMET PEER DEPENDENCY typescript@>=2.7
npm WARN ts-node@8.10.2 requires a peer of typescript@>=2.7 but none was installed.
没安装上ts-node,在网上也找不到解决办法,大神知道怎么解决么
The text was updated successfully, but these errors were encountered: