mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
bf2c3af93b
Summary: `react-native/codegen` uses `babel/parser` and `babel/core` but does not declare dependency on them. Depending on how packages are hoisted (and especially in pnpm setups), this causes crashes during codegen. Resolves https://github.com/facebook/react-native/issues/52883 ## Changelog: [GENERAL] [FIXED] - Add missing Babel dependencies Pull Request resolved: https://github.com/facebook/react-native/pull/52884 Test Plan: See https://github.com/facebook/react-native/issues/52883 Reviewed By: cortinico, christophpurrer Differential Revision: D79103092 Pulled By: robhogan fbshipit-source-id: ecaf690f994393a652ea7f0d4f30bbabeb23a434
@react-native/codegen
Installation
yarn add --dev @react-native/codegen
Note: We're using yarn to install deps. Feel free to change commands to use npm 3+ and npx if you like
Testing
To run the tests in this package, run the following commands from the React Native root folder:
yarnto install the dependencies. You just need to run this onceyarn jest packages/react-native-codegen.