question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Could not find a declaration file for module 'inquirer'.

See original GitHub issue

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

node_modules/nest-commander/src/inquirer.service.d.ts:2:42 - error TS7016: Could not find a declaration file for module 'inquirer'. '/usr/src/app/node_modules/nest-commander/node_modules/inquirer/lib/inquirer.js' implicitly has an 'any' type.    
Try `npm i --save-dev @types/inquirer` if it exists or add a new declaration (.d.ts) file containing `declare module 'inquirer';`

Minimum reproduction code

  1. install nest-commander
  2. create a command with it
  3. run app

Expected behavior

No error is shown.

Package

  • nest-commander
  • nest-commander-schematics
  • nest-commander-testing

Package version

2.3.4

Node.js version

17.2.0

In which operating systems have you tested?

  • macOS
  • Windows
  • Linux

Other

No response

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:18 (7 by maintainers)

github_iconTop GitHub Comments

2reactions
uiiicommented, Dec 21, 2021

Feel free to make a PR to address this. Otherwise I’ll try to get to it later this week

I can wait I will install @types/inquirer

1reaction
jmcdo29commented, Dec 21, 2021

Feel free to make a PR to address this. Otherwise I’ll try to get to it later this week

Read more comments on GitHub >

github_iconTop Results From Across the Web

Could not find a declaration file for module 'module-name ...
In order for this to work, I had to make declare module '...' the first line of code in the module.d.ts file, and...
Read more >
Could not find declaration file for module 'X' Error | bobbyhadz
The error "Could not find a declaration file for module" occurs when TypeScript cannot find the type declaration for a module. To solve...
Read more >
How to fix error TS7016: Could not find a declaration file for ...
Try `npm install @types/XYZ` if it exists or add a new declaration (.d. · declare module 'XYZ';. Lastly, you also need to add...
Read more >
Error: Could not find a declaration file for module - YouTube
Fix error: Could not find a declaration file for module ... implicitly has an 'any' type.Try npm install library-name if it exists or...
Read more >
Could not find a declaration file for module '@reactivex/rxjs ...
Try npm install @types/@reactivex/rxjs if it exists or add a new declaration (.d.ts) file containing declare module '@reactivex/rxjs';.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found