tagged Jul 5, 2016 · 4523 commits to master since this release

Assets 4

Likely to cause new Flow errors:

  • Significant fix to matching members of union types. This fix very likely surfaces typechecking issues that were missed before. Check out the blog post for more details
  • Variables in template literals are now subject to the same rules as variables being concatenated with a string using +. This may surface template strings with variables that may not safely coerce to a string.
  • Type arguments are now required to be specified for type annotations that have type arguments. Previously they were implicitly filled in as any -- but now this must be explicit. This behavior is toggleable via experimental.strict_type_args=false, but this config option will be removed in a near-term future release. There is also a codemod to help you automatically update old code.

New Features:

  • Support for declare export within declare module bodies. When declare export is used, the module being declared is inferred as an ES module. This enables the ability to export both named and default exports using declare module.

Notable bug fixes:

  • Fixed a bug on OSX where Flow might crash in rare circumstances
  • Fixed an issue where automatic semicolon insertion for class properties wasn't behaving properly in some circumstances.
  • It is no longer required to annotate a property on an exported class if an initializer value is present. Instead, the initializer value itself can be directly annotated. This makes annotation of class properties that are functions much less cumbersome.
  • Fixed a race-condition where Flow may not properly error when it encounters two modules with the same name (using the "haste" module system)


  • Flow now looks for @flow in all comments at the top of the file (rather than just the first). It's also possible to configure this using a new max_header_tokens .flowconfig option.
  • Various built-in libdef improvements
  • Performance improvements for the flow coverage command