A framework for building native applications using React
Use hermes-parser for Flow codegen specs (#39036)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/39036 Changelog: [General][Changed] Use `hermes-parser` instead of `flow-parser` to parse Flow Codegen specs. `hermes-parser` is a WASM build of the Hermes parser (plus supporting code), maintained by the Flow and Hermes teams. It is the recommended way of parsing Flow code in Node and its benefits (compared to `flow-parser`) include better performance and improved type safety. Here we update `react-native/codegen` to use `hermes-parser` instead of `flow-parser`. Both parsers produce ASTs that conform to the ESTree spec so this is mostly a drop-in replacement. In future work we should be able to use the improved AST types available in `hermes-estree` to improve type safety within `react-native/codegen` itself. Reviewed By: huntie Differential Revision: D48384078 fbshipit-source-id: 310ad150ec62671ba395b0e2f6415ccae97ac04d
M
Moti Zilberman committed
5abaf388cde499747e81ecb73aa01fa819dbbd47
Parent: a74765e
Committed by Facebook GitHub Bot <[email protected]>
on 11/8/2023, 9:33:42 AM