1.4 KiB
npmHooks.npmConfigHook
Hook for configuring packages that use npm. Primarily made for a multi-language environment.
Examples
Variables controlling npmConfigHook
npmConfigHook Exclusive Variables
npmDeps
Derivation that contains the npm package dependencies.
Usually built with fetchNpmDeps.
This attribute is required or the hook will abort the build.
makeCacheWritable
Whether to make the dependency cache writable prior to installing the dependencies. Don't set this unless npm tries to write to the cache directory.
npmInstallFlags
Flags to pass to the {command}npm ci call for installing the dependencies to the build environment.
Defaults to --ignore-scripts, which cannot be removed.
This does not control anything with the npmInstallHook.
npmRebuildFlags
Flags to pass to the {command}npm rebuild command after the dependencies are installed to the environment.
Honored Variables
The following variables are honored by the npmConfigHook.
npmWorkspacenpmFlagsnpmRoot