3 ms·
They've finally begun backtracking on function parameter bivariance. https://blogs.msdn.microsoft.com/typescript/2017/06/12/announcing-typescript-2-4-rc/ https:
by cassowary 9y ago
They've finally begun backtracking on function parameter bivariance. https://blogs.msdn.microsoft.com/typescript/2017/06/12/announcing-typescript-2-4-rc/ https://blogs.msdn.microsoft.com/typescript/2017/06/12/annou...
They still think they're right: "Our experience has been that users generally don't run into issues with this all that much", but they've started to "tighten[] things up and compare[] the parameters which are callbacks specifically". I'm just so excited and annoyed that they've finally partially admitted they're wrong. Double annoyed that we're still on TS 1.8 :(
I just don't understand function parameter bivariance. It's not just that it's wrong (if it was just theoretical I wouldn't've noticed), it's that it keeps letting bugs through. You simply can't refactor the code and then fix it till there's no errors because you'll run out of errors before you run out of things that need changing. Or adding features in React+Redux, can you get it to help you? Nup. At least that's a specific point you can remember to check.
- severus 9y agoTypescript has pretty good support for react and redux.