最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

node.js - render deployment failed with errors like srcapp.configuration.ts(12,26): error TS7016: Could not find a declaration f

programmeradmin3浏览0评论

I'm deploying my nodejs app on render after a successfull "yarn build" but keeps failing to deploy the app with the following errors:

    src/app.configuration.ts(12,26): error TS7016: Could not find a declaration file for module 'cookie-parser'. '/opt/render/project/src/node_modules/cookie-parser/index.js' implicitly has an 'any' type.
  Try `npm i --save-dev @types/cookie-parser` if it exists or add a new declaration (.d.ts) file containing `declare module 'cookie-parser';`
src/app.configuration.ts(13,21): error TS7016: Could not find a declaration file for module 'express-session'. '/opt/render/project/src/node_modules/express-session/index.js' implicitly has an 'any' type.
  Try `npm i --save-dev @types/express-session` if it exists or add a new declaration (.d.ts) file containing `declare module 'express-session';`
src/app.configuration.ts(14,20): error TS7016: Could not find a declaration file for module 'man'. '/opt/render/project/src/node_modules/man/index.js' implicitly has an 'any' type.
  Try `npm i --save-dev @types/man` if it exists or add a new declaration (.d.ts) file containing `declare module 'man';`
src/cron/test.cron.ts(1,18): error TS7016: Could not find a declaration file for module 'node-cron'. '/opt/render/project/src/node_modules/node-cron/src/node-cron.js' implicitly has an 'any' type.
  Try `npm i --save-dev @types/node-cron` if it exists or add a new declaration (.d.ts) file containing `declare module 'node-cron';`

I tried to install those indicated types, they are installed successful but keeps on failing to deploy the app on render.

Any help?

与本文相关的文章

发布评论

评论列表(0)

  1. 暂无评论