English 中文(简体)
类型、“处理”不存在
原标题:Typescript, "process" does not exist
  • 时间:2019-06-27 23:46:58
  •  标签:
  • node.js

我安装了<条码>npm i @types/node,但处理过程仍没有登记。 我还需要做些什么来为 no点确定哪类定义?

最佳回答

你们不仅必须安装 no的类型(见npm i @types/node),而且你还必须将“node”列入conf。 json

// example tsconfig.json
{
  "compilerOptions": {
    "module": "CommonJS",
    "target": "ES2018",
    "baseUrl": ".",
    "importHelpers": true,
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "types": ["node"]
  }
}
问题回答

目前,极为重要的是,如果你更新“类型”或“类型”的话,你就会制定一份独一无二的清单,以包括(你必须保持这一清单),而将其留任到all相关的可用类型地点。

https://www.typescriptlang.org/tsconfig#types https://www.typescriptlang.org/tsconfig#typeRoots





相关问题
How to make Sequelize use singular table names

I have an model called User but Sequelize looks for the table USERS whenever I am trying to save in the DB. Does anyone know how to set Sequelize to use singular table names? Thanks.

What is Node.js? [closed]

I don t fully get what Node.js is all about. Maybe it s because I am mainly a web based business application developer. What is it and what is the use of it? My understanding so far is that: The ...

Clientside going serverside with node.js

I`ve been looking for a serverside language for some time, and python got my attention somewhat. But as I already know and love javascript, I now want learn to code on the server with js and node.js. ...

Can I use jQuery with Node.js?

Is it possible to use jQuery selectors/DOM manipulation on the server-side using Node.js?

How do I escape a string for a shell command in node?

In nodejs, the only way to execute external commands is via sys.exec(cmd). I d like to call an external command and give it data via stdin. In nodejs there does yet not appear to be a way to open a ...

热门标签