Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/dtslint/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ Also:

For types that do not have a matching NPM package, add two properties:

1. `"nonNpm": true`
1. `"nonNpm": true`, or `"nonNpm": "conflict"` if there is a NPM package but it is unrelated.
Comment thread
fowl2 marked this conversation as resolved.
Outdated
2. `"nonNpmDescription"`, a human-readable name for the project that is being typed.

#### `types/.eslintrc.json`
Expand Down
3 changes: 2 additions & 1 deletion packages/dtslint/src/checks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,8 @@ export async function checkNpmVersionAndGetMatchingImplementationPackage(
errors.push(
`Package ${packageJson.name} is marked as non-npm, but ${packageName} exists on npm. ` +
`If these types are being added to DefinitelyTyped for the first time, please choose ` +
`a different name that does not conflict with an existing npm package.`,
`a different name that does not conflict with an existing npm package. If this is an ` +
`existing conflict, mark these types as \`"nonNpm": "conflict"\`.`,
);
} else if (!packageJson.nonNpm) {
if (!satisfies(packageVersion, typesPackageVersion)) {
Expand Down