wellcomecollection / wellcomecollection.org

🪟 Wellcome Collection's website and services that support it
https://wellcomecollection.org
MIT License
37 stars 5 forks source link

Get TS to use `strict: true` #10981

Open rcantin-w opened 2 days ago

rcantin-w commented 2 days ago

Now we've got an aligned TSconfig file, we'd like to move towards strict: true. A first step could be to add in the missing recommended complierOptions:

exactOptionalPropertyTypes |   | Stricter rules around how it handles properties on type or interfaces which have a ? prefix. noImplicitAny |   | TypeScript will issue an error whenever it would have inferred any. useUnknownInCatchVariables |   | For errors to be typed unknown as we don't know 100% it'll be an error type