electron-builder includes @types/yargs dependency, TypeScript has type errors on it
See original GitHub issue- Version: 22.9.1
- Electron Version: N/A
- Electron Type (current, beta, nightly): N/A
- Target: N/A
My project indirectly has @types/yargs
, due to it being a dependency of electron-builder
:
❯ npm ls @types/yargs
nunisynth@1.0.0 /home/trusktr/src/project-alpha
└─┬ electron-builder@22.9.1
└── @types/yargs@15.0.10
And TypeScript complains about it:
❯ npx tsc
node_modules/@types/yargs/index.d.ts:28:10 - error TS2305: Module '"../../yargs-parser/build/index.cjs"' has no exported member 'DetailedArguments'.
28 import { DetailedArguments, Configuration } from 'yargs-parser';
~~~~~~~~~~~~~~~~~
node_modules/@types/yargs/index.d.ts:28:29 - error TS2305: Module '"../../yargs-parser/build/index.cjs"' has no exported member 'Configuration'.
28 import { DetailedArguments, Configuration } from 'yargs-parser';
~~~~~~~~~~~~~
Found 2 errors.
Any ideas what’s going on with it?
Issue Analytics
- State:
- Created 3 years ago
- Comments:10
Top Results From Across the Web
Typescript cannot find modules that are already installed
I am trying to build a client that runs on Electron with Typescript, however, I am getting errors from the request.ts files.
Read more >Common Configuration
Type is specified after property name: Array<String> | String . ... false Boolean - Whether to build the application native dependencies from source....
Read more >TypeORM - Amazing ORM for TypeScript and JavaScript (ES7 ...
Supports both DataMapper and ActiveRecord (your choice). Entities and columns. Database-specific column types. Entity manager. Repositories and custom ...
Read more >yargs
Yargs helps you build interactive command line tools, by parsing arguments and generating an elegant user interface. It gives you:.
Read more >Node.js v19.3.0 Documentation
Building; Linking to libraries included with Node.js ... Node-API callback types ... Error behavior; Integrity checks; Dependency redirection ...
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 have the same problem
`node_modules/builder-util-runtime/out/httpExecutor.d.ts:2:10 - error TS2305: Module ‘“crypto”’ has no exported member ‘BinaryToTextEncoding’.
2 import { BinaryToTextEncoding } from “crypto”; ~~~~~~~~~~~~~~~~~~~~
`
npm i electron-updater@4.2.0