ts-reset
ts-reset copied to clipboard
A 'CSS reset' for TypeScript, improving types for common JavaScript API's
Hey @mattpocock, thanks for ts-reset. I've been thinking about making something similar for DOM specs. Several APIs say they exist, but they do not work across all browsers. My plan...
One annoying behaviour with typescript is that **control flow type narrowing does not work in unreachable code**. Even if the code is unreachable, the compiler will still complain on all...
@mattpocock kindly provide feedback on nrwl/nx#15196 regarding monorepo implementation with front-end and backend TS apps Nice work! Thank you!
It's a great idea not to "fix" `Object.keys` as it is not broken, I fully support that! But you could push the reasoning further and actually fix the various broken...
Resolves issue #55 Overrides dynamic require's return type from `any` to `unknown`. there may be a better way of overriding the NodeRequire interface which doesn't result in the `(+1 overload)`...
JSON.stringify has some caveats that is not in the standard Typescript implementation. `JSON.stringify(undefined)` returns `undefined`, not `string` `JSON.stringify(function(){})` returns `undefined `as well. This PR fixes that.
See: https://github.com/microsoft/TypeScript/issues/46958
Example: ```ts type ClientA = { firstName: string; lastName: string; isAdmin: boolean } type ClientB = { fullName: string; isAdmin: boolean } type ClientList = ClientA[] | ClientB[] const list:...
I've used this package in production at work for 7 months now. I know this package hasn't been updated in 8 months, but at the same time, I've not needed...
I found a problem when using an object with readonly keys and accessing one of them dynamically. It's tough to explain, so here's a minimal example: ```ts const test =...