Could not find a declaration file for module 'inquirer'.
See original GitHub issueIs 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
- install nest-commander
- create a command with it
- 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:
- Created 2 years ago
- Reactions:1
- Comments:18 (7 by maintainers)
Top 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 >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I can wait I will install
@types/inquirer
Feel free to make a PR to address this. Otherwise I’ll try to get to it later this week