Commit Graph

1525 Commits

Author SHA1 Message Date
Riccardo Cipolleschi e77fe5c471 Bump React Native monorepo packages (#48975)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48975

After cutting 0.78-stable, we need to bump the monorepo packages to `0.79.0-main`

## Changelog:
[Internal] - Bump monorepo packages to `0.79.0-main`

Reviewed By: cortinico, huntie

Differential Revision: D68715005

fbshipit-source-id: cb5abbf05e8638683687be8d61d66b3037111572
2025-01-27 11:01:34 -08:00
Alex Hunt d4c1c7bfe3 Move experimental type generation into dedicated script (#48867)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48867

Also:
- Rename output dir to `types_generated/`.
- Support source patterns outside of the `react-native` package.

Changelog: [Internal]

Reviewed By: j-piasecki

Differential Revision: D68498211

fbshipit-source-id: 7f9f540efd6d3d2c70b8b1721738f3fea569641d
2025-01-23 02:39:32 -08:00
Sam Zhou 7278ff01d7 Deploy 0.259.1 to xplat (#48751)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48751

Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D68294434

fbshipit-source-id: 8827369836906464566069cf22b584a4c672ec92
2025-01-16 16:29:30 -08:00
Pieter Vanderwerff c65117eba9 Deploy 0.259.0 to fbsource (#48744)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48744

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D68279682

fbshipit-source-id: 2a7e19b75863d5fd31037e04fa334efda28de79e
2025-01-16 11:43:13 -08:00
Tim Yung 85e58f334e Prettier: Cleanup eslint-plugin-prettier Dependency (#48524)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48524

I've confirmed that we are no longer using `eslint-plugin-prettier` in Metro or React Native. This removes it from the package dependencies.

Changelog:
[Internal]

Reviewed By: huntie

Differential Revision: D67920511

fbshipit-source-id: 9c8036ccfb94d974d344d861942c076dc2b70125
2025-01-08 09:42:59 -08:00
Sam Zhou abf0384434 Deploy 0.258.1 to xplat
Summary: Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D67927891

fbshipit-source-id: ac9c7bd87e9f1e2fecdbd7141cd0e5c5a62c7ce6
2025-01-08 08:47:41 -08:00
Rubén Norte 96205dd78e Add tinybench to run benchmarks in Fantom (#48453)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48453

Changelog: [internal]

Adds tinybench 3.1.0 (which has support for sync execution) and defined Flow types for the package.

Reviewed By: dmytrorykun

Differential Revision: D66698545

fbshipit-source-id: faf44add74e5711ac0d50794ce3360eedc45f0a5
2025-01-06 07:10:28 -08:00
Sam Zhou b030418649 Deploy 0.258.0 to xplat (#48482)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48482

Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D67810693

fbshipit-source-id: 82e858d4d5ef3c9896ea3bd58a4f4364dce5bdd0
2025-01-03 15:37:43 -08:00
Sam Zhou 66342d3ccd Deploy 0.257.1 to xplat
Summary: Changelog: [Internal]

Reviewed By: panagosg7

Differential Revision: D67548045

fbshipit-source-id: 0c983b327b54580dddf483b6250ff1261df8ce75
2024-12-20 15:58:17 -08:00
Sam Zhou b8f3f919cc Deploy 0.257.0 to xplat (#48331)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48331

Changelog: [Internal]

Reviewed By: pieterv

Differential Revision: D67423622

fbshipit-source-id: 09ca17bedf15174e210e943b989537c67f197659
2024-12-18 17:39:30 -08:00
Riccardo Cipolleschi 4368368ef5 Fix some peer dependencies on React types (#48292)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48292

These dependencies are making the CI on main to fail.

## Changelog:
[General][Fixed] - Fix peer dependencies on React types

Reviewed By: javache, hoxyq

Differential Revision: D67283609

fbshipit-source-id: b325246f5de654a9ccbf7f96eec24434047a38ee
2024-12-16 14:08:19 -08:00
Riccardo Cipolleschi 5a81ceed2a React Native sync for revisions de68d2f...372ec00 (#48196)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48196

X-link: https://github.com/facebook/metro/pull/1400

- **[372ec00c03](https://github.com/facebook/react/commit/372ec00c03 )**: Update ReactDebugInfo types to declare timing info separately ([#31714](https://github.com/facebook/react/pull/31714)) //<Sebastian Markbåge>//
- **[3d2ab01a55](https://github.com/facebook/react/commit/3d2ab01a55 )**: [Flight] Extract special cases for Server Component return value position ([#31713](https://github.com/facebook/react/pull/31713)) //<Sebastian Markbåge>//
- **[1c9b138714](https://github.com/facebook/react/commit/1c9b138714 )**: Don't serialize chunk ids for Hint and Console rows ([#31671](https://github.com/facebook/react/pull/31671)) //<Sebastian Markbåge>//
- **[de68d2f4a2](https://github.com/facebook/react/commit/de68d2f4a2 )**: Register Suspense retry handlers in commit phase ([#31667](https://github.com/facebook/react/pull/31667)) //<Josh Story>//
- **[16d2bbbd1f](https://github.com/facebook/react/commit/16d2bbbd1f )**: Client render dehydrated Suspense boundaries on document load ([#31620](https://github.com/facebook/react/pull/31620)) //<Josh Story>//
- **[5b0ef217ef](https://github.com/facebook/react/commit/5b0ef217ef )**: s/server action/server function ([#31005](https://github.com/facebook/react/pull/31005)) //<Ricky>//
- **[e3b7ef32be](https://github.com/facebook/react/commit/e3b7ef32be )**: [crud] Only export uRC when flag is enabled ([#31617](https://github.com/facebook/react/pull/31617)) //<lauren>//
- **[aba370f1e4](https://github.com/facebook/react/commit/aba370f1e4 )**: Add moveBefore Experiment ([#31596](https://github.com/facebook/react/pull/31596)) //<Sebastian Markbåge>//
- **[1345c37941](https://github.com/facebook/react/commit/1345c37941 )**: Mark all lanes in order on every new render ([#31615](https://github.com/facebook/react/pull/31615)) //<Sebastian Markbåge>//
- **[91061073d5](https://github.com/facebook/react/commit/91061073d5 )**: Mark ping time as update ([#31611](https://github.com/facebook/react/pull/31611)) //<Sebastian Markbåge>//
- **[a9f14cb44e](https://github.com/facebook/react/commit/a9f14cb44e )**: Fix Logging of Immediately Resolved Promises ([#31610](https://github.com/facebook/react/pull/31610)) //<Sebastian Markbåge>//
- **[c11c9510fa](https://github.com/facebook/react/commit/c11c9510fa )**: [crud] Fix deps comparison bug ([#31599](https://github.com/facebook/react/pull/31599)) //<lauren>//
- **[64f89510af](https://github.com/facebook/react/commit/64f89510af )**: [crud] Enable on RTR FB builds ([#31590](https://github.com/facebook/react/pull/31590)) //<lauren>//
- **[7558ffe84d](https://github.com/facebook/react/commit/7558ffe84d )**: [crud] Fix copy paste typo ([#31588](https://github.com/facebook/react/pull/31588)) //<lauren>//
- **[7c254b6576](https://github.com/facebook/react/commit/7c254b6576 )**: Log yielded time in the Component Track ([#31563](https://github.com/facebook/react/pull/31563)) //<Sebastian Markbåge>//
- **[6177b18c66](https://github.com/facebook/react/commit/6177b18c66 )**: Track suspended time when the render doesn't commit because it suspended ([#31552](https://github.com/facebook/react/pull/31552)) //<Sebastian Markbåge>//
- **[eaf2d5c670](https://github.com/facebook/react/commit/eaf2d5c670 )**: fix[eslint-plugin-react-hooks]: Fix error when callback argument is an identifier with an `as` expression ([#31119](https://github.com/facebook/react/pull/31119)) //<Mark Skelton>//
- **[047d95e85f](https://github.com/facebook/react/commit/047d95e85f )**: [crud] Basic implementation ([#31523](https://github.com/facebook/react/pull/31523)) //<lauren>//
- **[92c0f5f85f](https://github.com/facebook/react/commit/92c0f5f85f )**: Track separate SuspendedOnAction flag by rethrowing a separate SuspenseActionException sentinel ([#31554](https://github.com/facebook/react/pull/31554)) //<Sebastian Markbåge>//
- **[053b3cb050](https://github.com/facebook/react/commit/053b3cb050 )**: [crud] Rename Effect type ([#31557](https://github.com/facebook/react/pull/31557)) //<lauren>//
- **[7dd6b9e68a](https://github.com/facebook/react/commit/7dd6b9e68a )**: [crud] Add enableUseResourceEffectHook flag ([#31556](https://github.com/facebook/react/pull/31556)) //<lauren>//
- **[d8afd1c82e](https://github.com/facebook/react/commit/d8afd1c82e )**: [crud] Scaffold initial types ([#31555](https://github.com/facebook/react/pull/31555)) //<lauren>//
- **[3720870a97](https://github.com/facebook/react/commit/3720870a97 )**: Log Render Phases that Never Committed ([#31548](https://github.com/facebook/react/pull/31548)) //<Sebastian Markbåge>//
- **[8a41d6ceab](https://github.com/facebook/react/commit/8a41d6ceab )**: Unify RootDidNotComplete and RootSuspendedWithDelay exit path  ([#31547](https://github.com/facebook/react/pull/31547)) //<Sebastian Markbåge>//
- **[63cde684f5](https://github.com/facebook/react/commit/63cde684f5 )**: (chore): copy fix in <style> precedence error ([#31524](https://github.com/facebook/react/pull/31524)) //<Zack Tanner>//
- **[b01722d585](https://github.com/facebook/react/commit/b01722d585 )**: Format event with "warning" yellow and prefix with "Event: " ([#31536](https://github.com/facebook/react/pull/31536)) //<Sebastian Markbåge>//
- **[c13986da78](https://github.com/facebook/react/commit/c13986da78 )**: Fix Overlapping "message" Bug in Performance Track ([#31528](https://github.com/facebook/react/pull/31528)) //<Sebastian Markbåge>//
- **[4686872159](https://github.com/facebook/react/commit/4686872159 )**: Log passive commit phase when it wasn't delayed ([#31526](https://github.com/facebook/react/pull/31526)) //<Sebastian Markbåge>//
- **[5d89471ca6](https://github.com/facebook/react/commit/5d89471ca6 )**: Export __COMPILER_RUNTIME in stable ([#31540](https://github.com/facebook/react/pull/31540)) //<lauren>//
- **[3644f0bd21](https://github.com/facebook/react/commit/3644f0bd21 )**: Use completedRenderEndTime as the start of the commit phase if it's an immediate commit ([#31527](https://github.com/facebook/react/pull/31527)) //<Sebastian Markbåge>//
- **[8657869999](https://github.com/facebook/react/commit/8657869999 )**: Separate Tracks for Components and Phases ([#31525](https://github.com/facebook/react/pull/31525)) //<Sebastian Markbåge>//
- **[b15135b9f5](https://github.com/facebook/react/commit/b15135b9f5 )**: [ez] Update useMemoCache return type ([#31539](https://github.com/facebook/react/pull/31539)) //<lauren>//

Changelog:
[General][Changed] - Bump React from 18.3.1 to 19.0.0

bypass-github-export-checks
jest_e2e[run_all_tests]

Reviewed By: cortinico

Differential Revision: D67018480

fbshipit-source-id: 39bca3261ffaa8bb7d74187510724d77cc36b196
2024-12-16 06:58:21 -08:00
Alex Taylor (alta) 8aeba2a3b8 Deploy 0.256.0 to xplat (#48190)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48190

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D66979174

fbshipit-source-id: d94e8c42edd225fe367aac75e55d2c1d054acc07
2024-12-10 01:47:05 -08:00
Andrew Datsenko a8a136f3ef Add .toMatchSnapshot() (#48029)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48029

Changelog: [Internal]

Adding snapshot support for rendered output only for now.
This will only work if snapshot is created beforehand by hand.

# Next steps
* Create snapshot when no prior snapshot is available
* Pass and update if instructed

Reviewed By: christophpurrer

Differential Revision: D66601387

fbshipit-source-id: fe528cded43c5ba36d314bd9af8e3fb84b98ac3e
2024-12-09 19:09:57 -08:00
Rubén Norte c54ba09d2e Add package.json script to run Fantom tests (#48144)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/48144

Changelog: [internal]

Adds package.json script to run Fantom tests:

```
yarn fantom
```

NOTE: At the moment, this only works on Meta's infra. We're working on making this available in OSS/Github CI.

Reviewed By: javache

Differential Revision: D66874962

fbshipit-source-id: d9746428b618a31ce0bf96c3233828cdba501dd6
2024-12-06 05:24:31 -08:00
Andrew Datsenko b27bd00a38 add jest-diff to dependencies (#47990)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47990

Changelog:
[General][Added] - add `jest-diff v29.7.0` to devDependencies

Reviewed By: NickGerleman

Differential Revision: D66541001

fbshipit-source-id: 01c59a936b66f85ce034b59c7928df3c3f8c2a01
2024-11-28 10:04:46 -08:00
Sam Zhou cb7cd89a10 Deploy 0.255.0 to xplat (#47941)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47941

Changelog: [Internal]

Reviewed By: pieterv

Differential Revision: D66477998

fbshipit-source-id: f4d1dbe506d6c42751fade897637031f0a43aa29
2024-11-25 16:06:09 -08:00
Panos Vekris d4d1eb9bb1 Deploy 0.254.2 to xplat (#47912)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47912

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D66379853

fbshipit-source-id: 3a7677c5a71ef74e509ed43be87e455aed0cbaa7
2024-11-22 21:48:38 -08:00
Sam Zhou 12550f05c5 Deploy 0.254.1 to xplat (#47887)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47887

Changelog: [Internal]

Reviewed By: alexmckenley

Differential Revision: D66315470

fbshipit-source-id: 16b8fca3412fc2fcea3be8dfd0c760d97c56d734
2024-11-21 13:13:10 -08:00
Pieter Vanderwerff ae09827b15 Deploy 0.254.0 to xplat (#47810)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47810

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D66278779

fbshipit-source-id: 01dec1dc844607afa8f650c5acdebc6d5d5739d2
2024-11-21 08:26:07 -08:00
Alex Hunt 113337f269 Update hermes-parser and related packages in fbsource to 0.25.1 (#47573)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47573

Bump hermes-parser and related packages to [0.25.1](https://github.com/facebook/hermes/blob/main/tools/hermes-parser/js/CHANGELOG.md).

Changelog: [Internal]

Reviewed By: robhogan

Differential Revision: D65816542

fbshipit-source-id: cb445eb77790fb2632d3bc318c6eb59f097b1518
2024-11-21 05:41:39 -08:00
Rubén Norte 737045217b Implement expect().toEqual() (#47697)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47697

Changelog: [internal]

Implements `expect(received).toEqual(expected)` in Fantom tests.

Reviewed By: sammy-SC

Differential Revision: D66108539

fbshipit-source-id: 4e1d2405064900ec9859220fb6a28ec25a5176f3
2024-11-20 04:27:10 -08:00
Alex Hunt 35ab62cca3 Substitute @pkgjs/parseargs for Node builtin (#47704)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47704

Now that we have a min requirement of Node 18.18 on `main`, drop dependency on this polyfill.

Changelog: [Internal]

Reviewed By: vzaidman

Differential Revision: D66162328

fbshipit-source-id: e8ab6669fe14ed177eccf4b861c01df4fb0d405a
2024-11-19 09:47:40 -08:00
Sam Zhou bea6229a5d Deploy 0.253.0 to xplat (#47622)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47622

Changelog: [Internal]

Reviewed By: alexmckenley

Differential Revision: D65967280

fbshipit-source-id: 81ad422cc1d88682ab8ed5c0bf4d07df14295b62
2024-11-14 14:05:17 -08:00
Alex Taylor (alta) 84bfeec9b8 Deploy 0.252.0 to xplat + www (#47523)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47523

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D65666666

fbshipit-source-id: 19f75611805777115febfca79d0945d31b7ea522
2024-11-08 12:27:49 -08:00
Nicola Corti 7e268c9d52 Revert React 19RC to React 18.3.1 (#47380)
Summary:
While we're waiting for 19 stable, let's bring main back to 18.3.1 ahead of the 0.77 branch cut. We'll land this change just after 19 stable lands.

This is a cherry pick of b93b378fa0 which landed in 0.76 already

bypass-github-export-checks

## Changelog:

[INTERNAL] - Revert React 19RC to React 18.3.1

Pull Request resolved: https://github.com/facebook/react-native/pull/47380

Test Plan: CI

Reviewed By: cipolleschi

Differential Revision: D65430775

Pulled By: cortinico

fbshipit-source-id: f0f211754c8ffe5d037fd299e4de52c29d1d7913
2024-11-08 08:27:37 -08:00
Panos Vekris e3f8c63698 Deploy 0.251.1 to xplat (#47317)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47317

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D65233278

fbshipit-source-id: 35057c00f9377b6492f43bb03e5f92572799a50a
2024-10-30 14:37:10 -07:00
Alex Taylor (alta) e797135247 Deploy 0.251.0 to www + fbsource (#47295)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47295

Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D65176860

fbshipit-source-id: 2254fdac49a664f3a92ae0834c76d721132fddc4
2024-10-29 19:31:15 -07:00
Rubén Norte 66df63d3b5 Generalize feature flags script (#47208)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47208

Changelog: [internal]

Small change to unify the yarn commands for feature flags into a single `featureflags` command with options.

Reviewed By: NickGerleman, mdvacca

Differential Revision: D64982509

fbshipit-source-id: 3f9d7ac35f61950bd03fef243e1a95625144a0cd
2024-10-29 08:02:54 -07:00
Sam Zhou 797d013308 Deploy 0.250.0 to xplat (#47108)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47108

Changelog: [Internal]

Reviewed By: panagosg7

Differential Revision: D64577261

fbshipit-source-id: 265e1f6755fde3836bb7aa15116e2bb380cee091
2024-10-17 19:54:04 -07:00
Alex Hunt 52ea8b07e2 Specify package manager version for project (#47091)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47091

Prompted by https://github.com/facebook/react-native/pull/47083, this change adds a `"packageManager"` field to the root `package.json` specifying `yarn@1.22.22`. This will configure a compatible, predictable version of Yarn for users using [Corepack](https://nodejs.org/api/corepack.html) via the Yarn Modern install process.

See https://yarnpkg.com/getting-started/install and https://nodejs.org/api/corepack.html.

Tested on a fresh system (GitHub Codespaces).

Changelog: [Internal]

Reviewed By: robhogan

Differential Revision: D64536673

fbshipit-source-id: 535c0ca725172e4a06de04b19c6cd2d31788f5a4
2024-10-17 07:55:07 -07:00
Sam Zhou 10d8c0df29 Deploy 0.249.0 to xplat (#47077)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47077

Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D64512638

fbshipit-source-id: 6c61e13ef0b02f755a150a4d31312375ca487076
2024-10-17 00:09:24 -07:00
Rob Hogan 0902b0af75 Update Metro to 0.81.0 (#47012)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47012

Update Metro from `0.81.0-alpha.2` to `0.81.0`.

This is also intended to be the final, stable release for RN 0.76.

Changelog:
[General][Changed]: Update Metro to 0.81.0

Reviewed By: blakef

Differential Revision: D64329574

fbshipit-source-id: e12bed356b46e4ed68c75b397b7f9e2228c377be
2024-10-14 10:08:36 -07:00
Sam Zhou 60bc3c5aed Deploy 0.248.1 to xplat (#47004)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/47004

Changelog: [Internal]

Reviewed By: panagosg7

Differential Revision: D64280903

fbshipit-source-id: f3f7a7bfdab30574fa911ba940032255932cd508
2024-10-13 12:58:21 -07:00
Sam Zhou 105aa129d8 Deploy 0.248.0 to fbsource
Summary: Changelog: [Internal]

Reviewed By: cortinico

Differential Revision: D64225120

fbshipit-source-id: ce00574ea5d367737191ac430017332799906ebe
2024-10-11 09:59:44 -07:00
Sam Zhou 94009f30e0 Update hermes-parser and related packages in fbsource to 0.24.0 (#46802)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46802

Bump hermes-parser and related packages to [0.24.0](https://github.com/facebook/hermes/blob/main/tools/hermes-parser/js/CHANGELOG.md).

Changelog: [internal]

Reviewed By: javache

Differential Revision: D63797332

fbshipit-source-id: 98179d3cd777ff6824dfd10ceb7236a02dc6c9d6
2024-10-03 08:20:16 -07:00
Alex Hunt 7c2a7de162 Bump Metro to 0.81.0-alpha.2 (#46703)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46703

Updates us in line with the release branch and unblocks https://github.com/facebook/react-native/pull/46627.

Changelog: [Internal]

Reviewed By: hoxyq

Differential Revision: D63544047

fbshipit-source-id: 4c093e6c2fc389888f12063df013db7023761859
2024-10-01 11:27:41 -07:00
Panos Vekris d75e917753 Deploy 0.247.1 to xplat (#46710)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46710

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D63560047

fbshipit-source-id: a43ac647fee12115c794aa8002bd340a4c4bcf16
2024-09-27 15:27:53 -07:00
Alex Hunt 33b78ee080 Substitute babel-preset-fbjs for metro-transform-plugins (#46689)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46689

Resubmission of D61014834 / https://github.com/facebook/react-native/pull/45959 (previously reverted).

> Addresses TODO comment. I noticed this lone reference to babel-preset-fbjs (last published 3y ago) while attempting to upgrade our Babel Flow syntax plugin.

Changelog: [Internal]

Reviewed By: hoxyq

Differential Revision: D63532211

fbshipit-source-id: e94b55b7b61194b50131b36a2fe817e149152953
2024-09-27 10:36:42 -07:00
Sam Zhou efe51044b8 Deploy 0.247.0 to fbsource
Summary: Changelog: [Internal]

Reviewed By: panagosg7

Differential Revision: D63506281

fbshipit-source-id: a992a1786a570f5d9562fbec71e0d2628c139bf3
2024-09-27 00:23:22 -07:00
Alex Taylor (alta) 582c33b13e Deploy 0.246.0 to xplat + www (#46519)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46519

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D62763246

fbshipit-source-id: db0296d9ec5c04374c9cacb947b4879671044264
2024-09-17 15:07:17 -07:00
anirudh.bharti 7cdb87eb19 chore: replace mkdirp with mkdir fs (#46388)
Summary:
This pull request replaces the use of mkdirp with Node.js's built-in fs.mkdirSync({ recursive: true }) function, which is available in Node.js version 10.12.0 and above. This change reduces the number of external dependencies and simplifies the codebase by using the native capabilities of Node.js.

The motivation behind this change is to remove the unnecessary mkdirp dependency, as Node.js natively supports recursive directory creation since version 10.12.0. This streamlines the code and reduces the reliance on external libraries.

## Changelog:

[INTERNAL] [REMOVED] - Replaced mkdirp with fs.mkdirSync({ recursive: true }) in build scripts and codegen. Requires Node.js 10.12.0 and above.

Pull Request resolved: https://github.com/facebook/react-native/pull/46388

Test Plan: I ran the build and codegen scripts locally with Node.js version 10.12.0 and above after replacing mkdirp, ensuring the scripts work as expected. No issues were encountered, and all processes, including directory creation and file handling, function correctly.

Reviewed By: cortinico

Differential Revision: D62852488

Pulled By: huntie

fbshipit-source-id: 76f44102a80b499521c156308d276a17d279ce38
2024-09-17 07:03:44 -07:00
Saad Najmi 8ac80e39ea Revert "feat: build codegen on postinstall (#46227)" (#46420)
Summary:
This reverts commit 0cb97f0261.

Revert this commit that adds a `post install` script for a couple of reasons:

1. (EDIT: This turns out to be unrelated) The `postinstall` script causes `yarn install` to fail on React Native macOS, where we use Yarn 4. I'm not entirely sure why, but I probably won't debug it for the rest of the reasons.
2. `postinstall` scripts (at least inside Microsoft) are viewed as a security risk. Any package in your dependency tree can get compromised, add the phase, and run arbitrary code. This has happened in the past with React Native past if I recall correctly. As such, we disable `postinstall` scripts in many of our repos (including `rnx-kit` and `react-native-test-app`).
3. The issue this is trying to solve is to help newcomers avoid a stale cache when they switch branches in the React Native monorepo and only run `yarn install`. I think it would be sufficient to add some documentation somewhere that it is expected one runs `yarn && yarn build` to use this repo locally? That's a fairly common practice in monorepos, at least ones inside Microsoft.

## Changelog:

[INTERNAL] [SECURITY] - Remove post install script phase in the React Native monorepo

Pull Request resolved: https://github.com/facebook/react-native/pull/46420

Test Plan: CI should pass

Reviewed By: christophpurrer, robhogan, cortinico, rshest

Differential Revision: D62755022

Pulled By: huntie

fbshipit-source-id: bf94ed33e3e451ea337ef7a6984f7ba964d0b212
2024-09-16 09:14:54 -07:00
Riccardo Cipolleschi 120558c0cd Bump main to 0.77
Summary:
This change bumps the React Native version in main to 0.77

bypass-github-export-checks

## Changelog:
[General][Changed] - Bump main to 0.77-main

## Facebook:
generated by running `js1 publish react-native 0.77.0-main`

Reviewed By: cortinico

Differential Revision: D62575939

fbshipit-source-id: 6d239fca2eed6cfe51f8c37f78d8dc8730c18b8c
2024-09-12 09:23:23 -07:00
Vitali Zaidman b37101486b update babel and fix tests accordingly (#46295)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46295

X-link: https://github.com/facebook/metro/pull/1343

Updated all **babel** packages in all `package.json` across the repo and ran `npx yarn-deduplicate yarn.lock --scopes babel`. Afterwards, fixed the following issues appearing as a result of that (squashed the following initially separate diffs to make this packages update work atomically):
### (D61336392) updated jest snapshot tests failing
### (D61336393) updated babel types and corrected typings accordingly
The latest babel 7 introduces the following features we need to adjust our types to:
* `JSXNamespacedName` is removed from valid `CallExpression` args ([PR](https://github.com/babel/babel/pull/16421))
  * `JSXNamespacedName` is used for namespaced XML properties in things like `<div namespace:name="value">`, but `fn(namespace:name)` doesn't make any sense.
* Dynamic imports are enabled behind a new flag `createImportExpressions` ([PR](https://github.com/babel/babel/pull/15682)), introducing calls such as `import(foo, options)`. These complicate the expected values passed to `import` to be more than just strings.
  * Since these are behind a flag that is not expected to be enabled, we can throw an error for now and whoever uses it can add a support to it if needed later.

### Added a new metro ENV ignore
`BROWSERSLIST_ROOT_PATH` is set to `""` explicitly in `xplat/js/BUCK`
and then ignored in
`js/tools/metro-buck-transform-worker/src/EnvVarAllowList.js`

Reviewed By: robhogan

Differential Revision: D61543660

fbshipit-source-id: abbcab72642cf6dc03eed5142eb78dbcc7f63a86
2024-09-05 07:11:17 -07:00
Sam Zhou 2bdcbb1c6b Deploy 0.245.2 to xplat (#46343)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46343

Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D62226470

fbshipit-source-id: 58fb884fa9071cb3f6c5d4a046ce0a494297a495
2024-09-05 00:45:35 -07:00
Sam Zhou eb02d5cb03 Deploy 0.245.1 to xplat (#46328)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46328

Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D62186461

fbshipit-source-id: 280794aac3b627af430fc132283b06d512c52f2d
2024-09-04 09:01:22 -07:00
Sam Zhou 7d7f94cc98 Deploy 0.245.0 to xplat (#46272)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46272

Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D62012136

fbshipit-source-id: ae94c6db62cdccec2ba3a175fb71464f16cbeb71
2024-08-30 09:14:54 -07:00
Vitali Zaidman 5cdfec9843 update metro version in react-native (#46264)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/46264

React-native was not in sync with metro changes that RN relies on

Changelog: [Internal]

Reviewed By: robhogan

Differential Revision: D61982240

fbshipit-source-id: 63b1f53174ab0ec663a537569a032c62c431eb83
2024-08-30 05:26:34 -07:00
Oskar Kwaśniewski 0cb97f0261 feat: build codegen on postinstall (#46227)
Summary:
This PR solves a small issue I've encountered when working with the repo.

When changing branches we often run `yarn` to reinstall dependencies (let's say we change from 0.74-stable to main).

There are lots of changes between those two versions in the `react-native-codegen` package. This causes an issue when we install pods in `packages/rn-tester` the old version of codegen is used (the one cached from 0.74-stable) leading to a big error that's hard to solve at first.

This PR solves this by building codegen on `postinstall`. I've seen many newcomers blocked by this issue (and rerunning `yarn` is the natural thing to do in this situation)

## Changelog:

[INTERNAL] [ADDED] - Build codegen on postinstall when working with the monorepo

Pull Request resolved: https://github.com/facebook/react-native/pull/46227

Test Plan: Run `yarn`

Reviewed By: cipolleschi

Differential Revision: D61849150

Pulled By: huntie

fbshipit-source-id: 24fc5cf9b6a2510298f7bcdce59043e5dcfbfdd4
2024-08-27 08:28:35 -07:00