From 1ed6a6287d285af39214188732ebd37e89970e08 Mon Sep 17 00:00:00 2001 From: Christoph Thiede <38782922+LinqLover@users.noreply.github.com> Date: Wed, 22 Dec 2021 20:25:06 +0100 Subject: [PATCH] Document banned npm names See also https://github.com/microsoft/dtslint/pull/349 and https://github.com/microsoft/dtslint/pull/350. As soon as an official decision for this issue exists, that should be referenced in the docs as well. --- src/index.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/index.ts b/src/index.ts index 2b57b51..99194c6 100644 --- a/src/index.ts +++ b/src/index.ts @@ -234,6 +234,15 @@ function assertPathIsInDefinitelyTyped(dirPath: string): void { } } +/** + * Starting at some point in time, npm has banned all new packages whose names + * contain the word `download`. However, some older packages exist that still + * contain this name. + * @NOTE for contributors: The list below list should ONLY be extended with + * packages for which there already exists a corresponding type definition + * package in the `@types` scope. More information: + * https://github.com/microsoft/dtslint/pull/351. + */ function assertPathIsNotBanned(dirPath: string) { const basedir = basename(dirPath); if (/(^|\W)download($|\W)/.test(basedir) &&