Languages

TypeScript - tsconfig.json file error: Cannot find type definition file for 'node'

3 points
Asked by:
Palus-Bear
1016

I've just created a new Nuxt 3 project (Vue.js) with tsconfig.json file and it keeps showing me the following error:

Cannot find type definition file for node

How can I fix this?

1 answer
3 points
Answered by:
Palus-Bear
1016

You need to install the node types.

Quick solution for npm:

npm install --save-dev @types/node

or using yarn:

yarn add @types/node --dev

Note:

If this doesn't fix the error, try to add "node" to your "types" array in tsconfig.json file and restart your IDE.

0 comments Add comment
Donate to Dirask
Our content is created by volunteers - like Wikipedia. If you think, the things we do are good, donate us. Thanks!
Join to our subscribers to be up to date with content, news and offers.
Native Advertising
🚀
Get your tech brand or product in front of software developers.
For more information Contact us
Dirask - we help you to
solve coding problems.
Ask question.

❤️💻 🙂

Join