diff options
author | nlf <quitlahok@gmail.com> | 2022-04-01 21:33:34 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-01 21:33:34 +0300 |
commit | 85b3c48d2c9bc4199aed699cc4c00ac96c5feebd (patch) | |
tree | 48376b309222e29f7352ae178a65e4033e691926 /docs | |
parent | 1a7d0d6f94c7f5e33e3426cf8e7a87dd7ad682dc (diff) |
docs(ci): add note that configuration must be consistent between install and ci (#4666)
related to #4664
Diffstat (limited to 'docs')
-rw-r--r-- | docs/content/commands/npm-ci.md | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/content/commands/npm-ci.md b/docs/content/commands/npm-ci.md index 97d1aa552..b4ce81186 100644 --- a/docs/content/commands/npm-ci.md +++ b/docs/content/commands/npm-ci.md @@ -46,6 +46,13 @@ In short, the main differences between using `npm install` and `npm ci` are: * It will never write to `package.json` or any of the package-locks: installs are essentially frozen. +NOTE: If you create your `package-lock.json` file by running `npm install` +with flags that can affect the shape of your dependency tree, such as +`--legacy-peer-deps`, you _must_ provide the same flags to `npm ci` or you +are likely to encounter errors. An easy way to do this is to run +`npm config set legacy-peer-deps=true --location=project` and commit the +`.npmrc` file to your repo. + ### Example Make sure you have a package-lock and an up-to-date install: |