Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: name and version description change #5753

Merged
merged 7 commits into from Nov 1, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
23 changes: 9 additions & 14 deletions docs/content/configuring-npm/package-json.md
Expand Up @@ -16,13 +16,11 @@ settings described in [`config`](/using-npm/config).
### name

If you plan to publish your package, the *most* important things in your
package.json are the name and version fields as they will be required. The
name and version together form an identifier that is assumed to be
completely unique. Changes to the package should come along with changes
to the version. If you don't plan to publish your package, the name and
version fields are optional.

The name is what your thing is called.
package.json are the name and version fields as they will be required.
The name and version together form an identifier that is assumed to be
completely unique.

wraithgar marked this conversation as resolved.
Show resolved Hide resolved
The name field contains your package name.

Some rules:

Expand Down Expand Up @@ -52,20 +50,17 @@ A name can be optionally prefixed by a scope, e.g. `@myorg/mypackage`. See

### version

If you plan to publish your package, the *most* important things in your
package.json are the name and version fields as they will be required. The
name and version together form an identifier that is assumed to be
completely unique. Changes to the package should come along with changes
to the version. If you don't plan to publish your package, the name and
version fields are optional.
Changes to the package should come along with changes to the version.
You can show developers how much they need to adjust on a new update by
using [semantic versioning](../../about-semantic-versioning)

Version must be parseable by
[node-semver](https://github.com/npm/node-semver), which is bundled with
npm as a dependency. (`npm install semver` to use it yourself.)

### description

Put a description in it. It's a string. This helps people discover your
Put a description in it. It's a string. This helps people discover your
wraithgar marked this conversation as resolved.
Show resolved Hide resolved
package, as it's listed in `npm search`.

### keywords
Expand Down