TypeScript starter should have `"strict": true` by default
I just lost a bit of time fixing uncaught type errors because I had assumed strict was enabled in tsconfig. Feels like it should be the default (this is the case for the other meta-frameworks I've used). Happy to send a PR if the maintainers agree :)
yeah I agree we should enable! Though it might not work properly yet because of you have to make our internals strict: true since we ship with the typescript.
@nksaraf right, yeah I guess there'll be some work to do to either fix or ignore issues in the internals :+1:
@nksaraf As a general rule, there should be no coupling between the tsconfig strictness of a library and the strictness of the code that uses that library. The solution is simple: the package.json "main" entry should not point to uncompiled TypeScript code, but should instead point to a compiled "dist" directory that contains both .js and .d.ts files. Setting things up this way, the TypeScript compiler is no longer required to compile the library code, and the app can be a strict or as non-strict as it wants, independently of the library's compilation options. This is how I have set up my own library builds and it works fairly well.
Duplicate of #140