fix: ensure strict checks are all recommended and related to#971
Conversation
- strictPropertyInitialization and alwaysStrict were missing from recommended even though the other Strict Checks were in there and all of them are enabled if strict is enabled - alwaysStrict, strictNullChecks, noImplicitAny, and noImplicitThis were missing from strict's relatedTo even though all are enabled if strict is enabled
|
I'm in favor of this change, I agree that it could encourage redundant tsconfig entries ( which does make me wonder if we could make a page which helps you trim / understand your tsconfig visually #972 ) but I think it helps folks who aren't going to jump straight to strict |
Doesn't the
TSDX itself had that too until I fixed it in jaredpalmer/tsdx#475. And I didn't notice the templates had them too until a user pointed it out in jaredpalmer/tsdx#619 and I fixed in jaredpalmer/tsdx#673, jaredpalmer/tsdx#690. The draft PR for monorepo template has redundancies too jaredpalmer/tsdx#778 (comment).. And I just noticed recently that we have That is to say, it seems to be super common with TS users and a lot don't seem to know how all the options work (e.g.
Yea that could be pretty helpful if enough folks know of it and use it. I was thinking a |
Description
strictPropertyInitialization and alwaysStrict were missing from
recommended even though the other Strict Checks were in there and all
of them are enabled if strict is enabled
alwaysStrict, strictNullChecks, noImplicitAny, and noImplicitThis were
missing from strict's relatedTo even though all are enabled if strict
is enabled
Tags
Found while working on #970.
Related to another PR I had on the topic of Strict Checks, #500
Review Notes
They're all listed as "recommended", but
strictenables all of them and is the only one turned on in@tsconfig/recommendand bytsc --init, so maybe all of them should be removed from "recommended" except forstrictinstead? Thoughts?