v0.30.0
Likely to cause new Flow errors:
- Fixed
React.PureComponent's definition, so previously missed errors are now reported - The definition of
consolein the build-in libdef has been filled out and is no longerany.
New Features:
- Forward references in type annotations: you can now reference a class in a type annotation before the class is declared
- T is now covariant in
Class<T>. So if classBextends classA, thenClass<B>is now a subtype ofClass<A> - Flow now lets you destructure objects with computed keys.
flow check-contents --respect-pragma-check-contentschecks whatever you give it, regardless of@flowor@noflow. This option changes the behavior to respect the pragma.flow check-contentswill now report parsing errors too (thanks @nmote!)
Notable bug fixes:
- Fixed
--tracebehavior when we unify types - Fixed situation where the client could spin-wait for the server
- Fixed non-termination triggered by certain calls to
Function.prototype.{apply,call} - Fixed issue where "Duplicate module provider" errors would stick around even after being fixed.
- (Windows) Fixed how the flow client tails the flow server's logs
- (Windows) Fixed the log rotating
- (Windows) Fixed issues where Flow would report Process Handles instead of Process IDs, leading to bad messages and a non-functional
flow stop - (Windows) Fixed build outside of a git or hg repository
- (Windows) Better error messages when you have paths that are too long
Misc:
undefinedis now just a global variable declared in the libdefs- Various built-in libdef improvements
- Nifty PR from @nmn which teaches flow that
nullableArr.filter(Boolean)is non-nullable