Closed codeBelt closed 2 years ago
I ended up renaming tsconfig.json
to tsconfig-base.json
and made tsconfig.json
look like:
{
"extends": "./tsconfig-base.json",
"compilerOptions": {
"strictNullChecks": true,
"plugins": [
{
"name": "typescript-strict-plugin",
"paths": ["./src/stores/", "./src/utils/"]
}
]
}
}
I think this works better because now my IDE displays the stricter warnings/errors but our build process can use the less strict version.
Maybe there should be a way to tell tsc-strict
to override strictNullChecks
or one of the other option(s) that is combined under the strict
option? Then I wouldn't have to do the tsconfig extend thing.
I guess my team is not liking all the strict null warnings in the IDE. Maybe allowing tsc-strict
to accept the --project
and -p
command line options is not a bad idea. Then I can slowly clean up the null warnings without the team seeing them.
To be honest we could actually pass all the arguments that typescript supports to the tsc
not only --project
. Right now we only pass --strict --noEmit
but adding support to pass --project
and the rest would be nice feature. I'll try to add this over the weekend. Thanks for the idea
Currently we use
"strict": true
but have"strictNullChecks": false
. When we runyarn tsc-strict
we get🎉 All files passed
.I am not sure how the plugin should work but I thought it would ignore the
strictNullChecks
and make ittrue
.I would like to keep the
tsconfig.json
as is and not remove"strictNullChecks": false
so it can work with our current workflow. Can you allowtsc-strict
to take the--project
and-p
command line options so we can point to another file (tsc-strict -p tsconfig-strict.json
)?