Skip to content

v0.249.0

Compare
Choose a tag to compare
@facebook-github-bot facebook-github-bot released this 16 Oct 23:54
· 13 commits to main since this release

Likely to cause new Flow errors:

  • Uses of React$AbstractComponent outside library definitions will now trigger internal-type lint error, which is on by default. React.AbstractComponent is also marked as deprecated. We recommend replacing them with component types. We have provided a codemod via the flow-upgrade package to aid larger codebases with this conversion: yarn run flow-codemod eliminateAbstractComponent path/to/src.

Notable bug fixes:

  • Fixed issue with StringPrefix and StringSuffix when used as a component syntax prop.
  • Fixed an issue that causes type argument inference on component type to be incorrectly under-constrained. (example)
  • Fixed as cast support in flow-remove-types.

Library Definitions:

  • React string refs are no longer supported in React.cloneElement. e.g. React.cloneElement(e, {ref: 'foo'}) will be an error.
  • The deprecated React$Ref type and various aliases of it are removed.