Skip to content

Latest commit

 

History

History
61 lines (44 loc) · 1 KB

pkg-normalize.md

File metadata and controls

61 lines (44 loc) · 1 KB

Enforces package normalization

Enforces package normalization and warns on moot properties.

Fail

{
  "name": "package",
  "version": "v1.0.0"
}

Version should be written as 1.0.0 instead.

{
  "name": "foo",
  "bin": {
    "foo": "cli.js"
  }
}

No need to use an object for bin, you can directly assign cli.js to it.

{
  "name": "package",
  "repository": "SamVerschueren/clinton",
  "bugs": "github.com/SamVerschueren/clinton/issues"
}

The bugs property is moot as it is automatically inferred by the repository field.

{
  "name": "package",
  "repository": "SamVerschueren/clinton",
  "homepage": "github.com/SamVerschueren/clinton"
}

The homepage property is moot as it is automatically inferred by the repository field.

Pass

{
  "name": "foo",
  "version": "1.0.0",
  "repository": "SamVerschueren/clinton",
  "bin": "cli.js"
}