diff --git a/content/cli/v10/configuring-npm/package-json.mdx b/content/cli/v10/configuring-npm/package-json.mdx index 8d00d0f0208..ed868657bd9 100644 --- a/content/cli/v10/configuring-npm/package-json.mdx +++ b/content/cli/v10/configuring-npm/package-json.mdx @@ -903,7 +903,7 @@ The `devEngines` field aids engineers working on a codebase to all be using the You can specify a `devEngines` property in your `package.json` which will run before `install`, `ci`, and `run` commands. -> Note: `engines` and `devEngines` differ in object shape. They also function very differently. `engines` is designed to alert the user when a dependency uses a differening npm or node version that the project it's being used in, whereas `devEngines` is used to alert people interacting with the source code of a project. +> Note: `devEngines` and `engines` differ in object shape and functionality. `devEngines` is used to declare the intended runtime (node, etc) and/or package manager (npm, etc) to be used by developers working directly in the source code of a project, whereas `engines` is intended for a package to declare the node and/or npm versions it is compatible with. The supported keys under the `devEngines` property are `cpu`, `os`, `libc`, `runtime`, and `packageManager`. Each property can be an object or an array of objects. Objects must contain `name`, and optionally can specify `version`, and `onFail`. `onFail` can be `warn`, `error`, or `ignore`, and if left undefined is of the same value as `error`. `npm` will assume that you're running with `node`. Here's an example of a project that will fail if the environment is not `node` and `npm`. If you set `runtime.name` or `packageManager.name` to any other string, it will fail within the npm CLI. diff --git a/content/cli/v11/configuring-npm/package-json.mdx b/content/cli/v11/configuring-npm/package-json.mdx index 98c85372cd4..4279f1d0c47 100644 --- a/content/cli/v11/configuring-npm/package-json.mdx +++ b/content/cli/v11/configuring-npm/package-json.mdx @@ -928,7 +928,7 @@ The `devEngines` field aids engineers working on a codebase to all be using the You can specify a `devEngines` property in your `package.json` which will run before `install`, `ci`, and `run` commands. -> Note: `engines` and `devEngines` differ in object shape. They also function very differently. `engines` is designed to alert the user when a dependency uses a differening npm or node version that the project it's being used in, whereas `devEngines` is used to alert people interacting with the source code of a project. +> Note: `devEngines` and `engines` differ in object shape and functionality. `devEngines` is used to declare the intended runtime (node, etc) and/or package manager (npm, etc) to be used by developers working directly in the source code of a project, whereas `engines` is intended for a package to declare the node and/or npm versions it is compatible with. The supported keys under the `devEngines` property are `cpu`, `os`, `libc`, `runtime`, and `packageManager`. Each property can be an object or an array of objects. Objects must contain `name`, and optionally can specify `version`, and `onFail`. `onFail` can be `warn`, `error`, or `ignore`, and if left undefined is of the same value as `error`. `npm` will assume that you're running with `node`. Here's an example of a project that will fail if the environment is not `node` and `npm`. If you set `runtime.name` or `packageManager.name` to any other string, it will fail within the npm CLI.