github facebook/flow v0.115.0

latest releases: v0.235.1, v0.234.0, v0.233.0...
4 years ago

Likely to cause new Flow errors:

  • In Types First mode, exported classes and functions cannot be reassigned.
  • Added similar checking of symbol in non-strict equality as other primitive types (example). We allow for non-strict equality checks between two symbol types, and between a symbol and null/void (example).
  • We now write properties to unsealed objects recorded during speculative checking, after speculation has succeeded.
  • Added more complete handling for indexers in spreads:
    • Use the indexer on the right, when the left is empty, exact and has no indexer. [example]
    • Allow matching indexers to be spread. [example]
  • Removed the non-array-spread lint, and replaced it with a new .flowconfig option, babel_loose_array_spread.

Notable bug fixes:

  • Improved union optimization for non-enum union equality checks.
  • Fixed a bug in which $Exact<T> failed when T resolved to a Shape<T>. [example]

Misc:

  • Improved performance of calculating the set of files that need to be checked.
  • Cached the typed AST as part of the persistent connection client info, to speed up requests coming from an LSP client (DefinitionRequest, Hover, TypeCoverage).
  • Improved dependency graph construction times, by using Hashtbl and mutable back edges.
  • Improved tool add-comments by
    • using flowlint-next-line instead of adding full $FlowFixMe suppressions on lints, and
    • making the rule for inserting comments inside JSX elements also apply to JSX fragments.
  • Upgraded to sedlex 2.1.

Don't miss a new flow release

NewReleases is sending notifications on new releases.