I'm authoring a package A which I want to publish to NPM.
A has a dependency on package B, which in turn has a dependency on package C. C then has two optional native dependencies D and E. I know for definite I have no use for the optional dependencies, D and E, and NEVER want to try and install them when someone installs my package.
I know you can use the command npm install A --no-optional -g
to install the package without optional dependencies, but this would be knowledge/overhead that I'd rather consumers of the package not need.
Is there any npm config or workaround where consumers of package A can just npm install A
or npm install -g A
and optional dependencies will never be installed?
Thanks