Skip to content
This repository has been archived by the owner on Nov 16, 2023. It is now read-only.

feat: Enforce noImplictAny #275

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all 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
8 changes: 7 additions & 1 deletion src/checks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,13 @@ export async function checkTsconfig(dirPath: string, dt: DefinitelyTypedInfo | u
}
}
} else {
for (const key of ["noImplicitAny", "noImplicitThis", "strictNullChecks", "strictFunctionTypes"]) {
for (const key of ["noImplicitAny"]) {
if (!options[key]) {
throw new Error(`Expected \`"${key}": true\`.`);
}
}

for (const key of ["noImplicitThis", "strictNullChecks", "strictFunctionTypes"]) {
if (!(key in options)) {
throw new Error(`Expected \`"${key}": true\` or \`"${key}": false\`.`);
}
Expand Down