Feature Request: Ignore Optional Dependencies
See original GitHub issueIt would be nice to have an option to ignore optionalDependencies
, which apparently are included with the invoked npm install --production
that gets triggered.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:8 (3 by maintainers)
Top Results From Across the Web
Option to ignore optional dependencies · Discussion #4960
Currently, the only way I found to not install optional deps was to force installing only production deps with NPM_ONLY_PRODUCTION and then, during...
Read more >Optional dependency groups omitting package requirements
To be clear: packages listed under omit wouldn't be uninstalled, and having them installed (e.g. manually, or as a dependency of another package) ......
Read more >Dependencies Management in Setuptools
There are three types of dependency styles offered by setuptools: 1) build system requirement, 2) required dependency and 3) optional dependency.
Read more >Maven – Optional Dependencies and Dependency Exclusions
The idea is that some of the dependencies are only used for certain features in the project and will not be needed if...
Read more >Specifying Dependencies - The Cargo Book
The package key, if not specified, defaults to the name of the dependency being requested. Note that if you have an optional dependency...
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
npm ls
doesn’t support--no-optional
. Looking for a workaround.This was a rabbit hole that led to npm/npm#17633. The
--no-optional
isn’t actually working innpm
for some time now. I see 2 options--no-shrinkwrap --no-optional
as an fix to npm/npm#17633package.json
file to readoptionalDependencies
I would prefer
1.
if you don’t anticipate side-effect of--no-shrinkwrap
for this module usage. Your take?aside: Hey! Last JS dev I did was in jQuery era, so am rusty 😃