-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs(lettable): mention TS >= 2.4 is required #2869
Conversation
Generated by 🚫 dangerJS |
@@ -4,6 +4,8 @@ Starting in version 5.5 we have shipped "lettable operators", which can be acces | |||
|
|||
**NOTE**: During 5.5 beta we will be bikeshedding a few of the names for operators that we had to give new names to due to keyword restrictions in javascript. | |||
|
|||
**NOTE**: If you're using TypeScript, version >= 2.4 is required, otherwise lettable operators will lose the type and compilation will break. | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a little more "doom and gloom" than I'd like.. It sounds like you can't use TypeScript 2.3 or under, which isn't true. It should just be NOTE: in TypeScript 2.3 and under, typings will need to be added to functions passed to operators
or something like that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even if it's true technically, in real world no one will do this. You really need to add the type to each functions, sometimes even twice, so that's clearly not usable. And in some way it's really an error, as lettable operators transfer the wrong type in TS < 2.4, then causing real compilation errors when you do any action on the data. But you're the owner, you choose what's best.
I've added a section to the docs to cover this in more detail. It can be found here Thank you for pointing out that we needed this, @cyrilletuzi |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Fixes #2856