mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Summary: PR https://github.com/facebook/react-native/issues/51078 Implemented finding disabled libraries but the code (below) didn't actually filter any libraries out because destructured name is `undefined`. This pr adds the name to codegenEnabledLibraries so filtering would work. ```js const libraries = codegenEnabledLibraries.filter( ({name}) => !disabledLibraries.includes(name), ); ``` ## Changelog: [IOS] [FIXED] - Skip codegen for selectively disabled libraries in react-native.config.js Pull Request resolved: https://github.com/facebook/react-native/pull/51838 Test Plan: 1. Install a library that has the componentProvider field set in the codegen config (for example: react-native-safe-area-context and react-native-screens or see [reproducer](https://github.com/aattola/rn-codegen-exclude)) 2. Exclude library with react-native.config.js 3. install pods / run codegen 4. Check that codegen actually excluded the specified dependencies from: `ios/build/generated/ios/RCTThirdPartyComponentsProvider.mm` Rollback Plan: Reviewed By: cortinico Differential Revision: D76044622 Pulled By: cipolleschi fbshipit-source-id: 9e70c2a263c750edb1ea95305c9e5e178e2ce8d8