Skip to content

Conversation

@blakef
Copy link
Collaborator

@blakef blakef commented Feb 28, 2024

I captured the history for the React Native template in a fairly blunt way (with an Original: trailer):

How

COMMITS=/tmp/commits
MESSAGE=/tmp/message
AUTHOR=/tmp/author
DATE=/tmp/date

CURRENT=head

TOTAL=$(wc -l $COMMITS | awk '{ print $1 }')

i=1
echo "Starting"
while true; do 
  if [[ -s $COMMITS ]]; then
      echo "Grabbing next commit: $i/$TOTAL"
      COMMIT=$(head -n 1 $COMMITS)
      tail -n +2 "$COMMITS" > "${COMMITS}.tmp" && mv "${COMMITS}.tmp" "$COMMITS"
  else
      echo "DONE: All commits done"
      exit 0
  fi
  pushd react-native
  git checkout --force $COMMIT

  export GIT_AUTHOR_NAME=$(git log --format=%an -n 1 "$COMMIT")
  export GIT_AUTHOR_EMAIL=$(git log --format=%ae -n 1 "$COMMIT")
  export GIT_AUTHOR_DATE=$(git log --format=%ad -n 1 "$COMMIT")
  export GIT_COMMITTER_NAME=$(git log --format=%cn -n 1 "$COMMIT")
  export GIT_COMMITTER_EMAIL=$(git log --format=%ce -n 1 "$COMMIT")
  export GIT_COMMITTER_DATE=$(git log --format=%cd -n 1 "$COMMIT")

  git log --format=%B -n 1 "$COMMIT" > $MESSAGE
  echo "Original: https://github.com/facebook/react-native/commit/$COMMIT" >> $MESSAGE
  cp -r packages/react-native/template ../template/
  popd

  git add template/
  git commit -F $MESSAGE

  echo "Progress: $i/$TOTAL"
  let i=i+1
done

I grabbed the commits this way:

git log --format=%H --reverse -- packages/react-native/template/ > /tmp/commits

What this gives us:

A commit history like this (notice the dates, author and Original link at the bottom):

commit 65aab467112970f256a01088f1ea2b47d6e1ea03 (HEAD -> history, fork/history, main)
Author: Riccardo Cipolleschi <cipolleschi@meta.com>
Date:   Thu Feb 22 05:10:57 2024 -0800

    Make the New Architecture the default (#43135)

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

    This change makes the New Architecture the default on both iOS and Android.
    This means that new application will be created using the New Architecture by default.

    It is still possible to opt out from it.

    ## Changelog
    [General][Changed] - Make the new architecture the default

    Reviewed By: cortinico, sammy-SC, dmytrorykun

    Differential Revision: D54006751

    fbshipit-source-id: bd7de0814925b65ab180105e18c1f6f275ba2672

    Original: https://github.com/facebook/react-native/commit/b9f3186ee6314f56863c05272640d47643709a39

hoxyq and others added 30 commits March 17, 2023 05:03
Summary:
Pull Request resolved: facebook/react-native#36434

Changelog: [Internal]

This is a squashed stack of 18 commits, starting from D43202126

allow-large-files

Reviewed By: cortinico

Differential Revision: D43977381

fbshipit-source-id: 0da552ddb85f2f61a0be0ef071915b35f3f8555c

Original: facebook/react-native@714b502
Summary:
With Metro symlink support coming soon, users will expect isolated `node_modules` resolution and hoisted `react-native` to work. Currently, we make some fragile assumptions in Ruby scripts about the location of `node_modules` packages - in particular `react-native` and `react-native-community/cli-platform-ios`.

This change invokes `node` to resolve those paths, which should allow these scripts to work in any Node JS-compliant setup.

There's a small (sub-second) performance penalty involved in invoking node, but two of these in the context of `pod install` seems reasonable. Also, these scripts [already invoke `node`](https://github.com/react-native-community/cli/blob/fb78fe8ea2fabe8e6d43f5042ecbb92e8e484e12/packages/cli-platform-ios/native_modules.rb#L26), so this isn't an additional dependency or point of failure.

*This is probably the first Ruby I've written in >10 years, review suggestions welcome!*

Changelog:
[iOS][Added] - Support workspace and isolated setups with `pod install`

Pull Request resolved: facebook/react-native#36485

Test Plan: `pod install` succeeds on a PNPM workspace setup where `react-native-community/cli` was not at the path previously expected by this script.

Reviewed By: cipolleschi

Differential Revision: D44097440

Pulled By: robhogan

fbshipit-source-id: 8300144888d8da019451b3f792b30eabc3a568cf

Original: facebook/react-native@0eff8d6
Summary:
Pull Request resolved: facebook/react-native#36631

Changelog: [Internal]

Hotfix for `main` branch CI stability after RN CLI `11.0.0` — the template as bootstrapped in CI needs to reference an exact version.

There is no published version (any more) for `11.0.0-alpha.2` (or `11.0.0-alpha.1`).

This is a temporary hotfix (we are trying to land facebook/react-native#36623, but are stuck on infra issues).

- `11.0.0-alpha.0` includes `metro@0.75.0` (compatible).

More info: facebook/react-native#36623 (comment)

Reviewed By: robhogan, NickGerleman

Differential Revision: D44371406

fbshipit-source-id: 870a59da521b55f957c8602125aecefb846e6ced

Original: facebook/react-native@155591b
Summary:
Pull Request resolved: facebook/react-native#36696

As the title says, we're converting the new app template to Kotlin.
This will reduce the template size and make it more aligned to market standards.

Changelog:
[Android] [Changed] - Convert the app template to Kotlin

Reviewed By: mdvacca

Differential Revision: D44142081

fbshipit-source-id: 6111360b6580460eba0341e47c55704cc673e444

Original: facebook/react-native@c1c22eb
Summary:
Pull Request resolved: facebook/react-native#36704

Following up to #36696, I accidentally failed a rebase and had files
commited on the wrong folder. I'm updating them here to use `packages/react-native/template`.

Changelog:
[Internal] [Changed] - Move from from accidental template/ folder on root

Reviewed By: cipolleschi

Differential Revision: D44502966

fbshipit-source-id: d408f38884444c4ecc03852b1d145bf2e89df672

Original: facebook/react-native@688df2f
Summary:
Pull Request resolved: facebook/react-native#36623

Changelog:
[General][Changed] - The default `metro.config.js` in apps now extends `react-native/metro-config`, and should be updated in existing apps.

~~`react-native/rn-get-polyfills.js` is removed and should be updated to `react-native/js-polyfills` in existing apps (this is part of the new default config).~~

#publish-packages-to-npm

## Context

### React Native Metro config → React Native repo (facebook/react-native#36502)

We (the React Native team) are aiming to relocate the default Metro config for React Native out of `react-native-community/cli-plugin-metro` and **into the React Native repo + app template** as a new `react-native/metro-config` package.

This is the first (and minimum viable) phase we can ship to separate the release process of Metro from RN CLI in order to reduce coupling and iterate faster for our users.

**See full motivation, design, and test plan (which previewed the CLI bump) here: facebook/react-native#36502

## Changes

NOTE: This PR is pending the inclusion of a bump to `react-native-community/cli`, and will be sequenced after react-native-community/cli#1875 is merged.

- Upgrade `react-native-community/cli` to `11.0.0`, upgrade all `metro` packages to `0.76.0` (version distributed in this CLI release).
- Update the `metro.config.js` file in `packages/react-native/template/`.
    - Now merges defaults from `react-native/metro-config`, and can be used with CLI >= 11.0.0.
- Update the `metro.config.js` files for `packages/react-native/` and `packages/rn-tester/` (these are integration test locations).
    - Now merges defaults from `react-native/metro-config`, and can be used with CLI >= 11.0.0.

Changes to `react-native/metro-config` — `0.72.1` (prepared but not depended on yet):

- Export `mergeConfig` util (removing direct `metro-config` dependency in consuming projects).
- Explicitly depend on `metro-react-native-babel-transformer` and `metro-runtime` (transitively included today).

Reviewed By: cortinico, blakef

Differential Revision: D44099691

fbshipit-source-id: 405635dd69fd50a1e9548279eaeda3c932b5b167

Original: facebook/react-native@c5a47ab
…n package (#36723)

Summary:
Pull Request resolved: facebook/react-native#36723

Changelog: [Internal]

Reviewed By: hoxyq

Differential Revision: D44542544

fbshipit-source-id: 70807edc8a183c28e1f0018a5426f4f2e29580a0

Original: facebook/react-native@f67bd67
Summary:
Changelog: [Internal]

Publishing to check CI if bumping and aligning in the same commit will work, since these new versions are not available on npm yet, but maybe our new monorepo setup will resolve this

**Adding back `react-native/virtualized-lists` as a workspace to `xplat/js` so that it won't be resolved from npm**

#publish-packages-to-npm

Pull Request resolved: facebook/react-native#36556

Reviewed By: cipolleschi

Differential Revision: D44255353

Pulled By: hoxyq

fbshipit-source-id: 21372487d6e9c0b2382b7cd9af835beed46b8ce1

Original: facebook/react-native@8a18b53
Summary:
Pull Request resolved: facebook/react-native#36795

This change bump the min iOS version for React Native to 13.4, to align with company guidelines.

## Changelog:
[iOS][Changed] - Moved the min iOS version to 13.4

Reviewed By: cortinico

Differential Revision: D44634663

fbshipit-source-id: 035e8fcbb395f7394f8253e3ec485ad9937531c2

Original: facebook/react-native@610b14e
Summary:
Pull Request resolved: facebook/react-native#36957

Fixes facebook/react-native#36830

This bumps the version of tsconfig/react-native to inform TypeScript of more libraries provided by Hermes/React Native. See tsconfig/bases@eee5f19.

I did the search off of current Hermes/RN main branch, but I think the new config should be valid as far back as 0.71. It doesn't make sense to change the new app template for an old version though, so instead I think we should include this new version in 0.72.

Changelog:
[General][Changed] - Bump tsconfig/react-native to 3.0.0

Reviewed By: cortinico

Differential Revision: D45085932

fbshipit-source-id: 448f1103ef13f76fa95884f790a3cccd9ff75b2f

Original: facebook/react-native@5c4649a
Summary:
This is follow up of Metro release 0.76.2 to Bump versions in RN.

Metro version: 0.76.2
Metro release notes: https://github.com/facebook/metro/releases/tag/v0.76.2
CLI Bump PR: react-native-community/cli#1910
CLI npm version: 12.0.0-alpha.3

Took changelog and testplan from facebook/react-native#36793

## Changelog:

[General][Fixed] - Bump CLI to 12.0.0-alpha.3 and Metro to 0.76.2

Pull Request resolved: facebook/react-native#36948

Test Plan: CircleCI

Reviewed By: huntie

Differential Revision: D45081058

Pulled By: jacdebug

fbshipit-source-id: 4c7b1004668ac30045577da54311bcab1a905ca9

Original: facebook/react-native@25709af
Summary:
Pull Request resolved: facebook/react-native#37018

Just bumping Gradle version to the latest stable.
This brings configuration caching as stable, which is quite of a big deal.

Changelog:
[Android] [Changed] - Gradle to 8.1

Reviewed By: yungsters

Differential Revision: D45177537

fbshipit-source-id: 6a47208b69d5591d299451e5a610cc3f5e9afe66

Original: facebook/react-native@74f256b
…layout (#37139)

Summary:
Pull Request resolved: facebook/react-native#37139

This dependency is unnecessary. React Native already exposes a `api` dependency on
`androidx.swiperefreshlayout:swiperefreshlayout` so every consumer will also get it.

This is just another line in the template we can effectively remove.

Changelog:
[Android] [Changed] - Do not explicitely depend on androidx.swiperefreshlayout:swiperefreshlayout

Reviewed By: cipolleschi

Differential Revision: D45390819

fbshipit-source-id: cce34c6a09100d36ee5eb003bb30323f64f0bb9c

Original: facebook/react-native@179d5ab
Summary:
Pull Request resolved: facebook/react-native#37220

I'm bumping Kotlin to 1.8.0 to align to the version used internally.

On top of this, I had to configure the JDK toolchain to 11 as Kotlin 1.8
was changing the default version of the stdlib it ships with by default.

This also shields us against problems once we'll bump to AGP 8 which requires
JDK 17 but still allows to produce libraries that are JDK 11 compatible.

Changelog:
[Android] [Changed] - Kotlin to 1.8.0 and JDK Toolchain to 11

Reviewed By: cipolleschi

Differential Revision: D45524689

fbshipit-source-id: 2558b5b6727b5d6e0e1e3cc58f0c6a85ddcefc4d

Original: facebook/react-native@74987b6
Summary:
https://devblogs.microsoft.com/typescript/announcing-typescript-5-0

## Changelog:

[GENERAL] [CHANGED] - Bump TypeScript in template from 4.8.4 to 5.0.4 and ESLint pkgs from 8.19.0 to 8.38.0

Pull Request resolved: facebook/react-native#36862

Test Plan: Everything builds and runs as expected

Reviewed By: cortinico

Differential Revision: D45720238

Pulled By: NickGerleman

fbshipit-source-id: d38b60110434760fdedc84ad941e0918bb986a40

Original: facebook/react-native@d2e446d
Summary:
Pull Request resolved: facebook/react-native#37345

This moves from `tsconfig/react-native`, a centralized repository of tsconfigs, to `react-native/typescript-config`, a package maintained as part of the RN monorepo.

We end up wanting to make changes where the versions are coupled, so this publishes them as part of the same repo, etc. It also means Meta engineers can more freely make changes to it with normal approval processes.

Changelog:
[General][Added] - Add react-native/typescript-config

Reviewed By: cortinico

Differential Revision: D45721088

fbshipit-source-id: b949bffb14014695abf3b9b359d3f5e30bfc8919

Original: facebook/react-native@cae52f6
Summary:
X-link: facebook/metro#987

While working on facebook/react-native#35786 I noticed some inconsistencies in the versioning for Babel and Flow across the monorepo. So in this PR I wanted to address that so that for 0.72 we'll have the codebase in a more consistent shape.

Happy to split in multiple PRs if needed.

## Changelog
[GENERAL] [CHANGED] - Bump Babel packages to ^7.20.0 (or closest latest release), bump flow parser to 0.206.0 in a few places that were left out from latest bump

Pull Request resolved: facebook/react-native#35787

Test Plan: CI is green.

Reviewed By: cipolleschi

Differential Revision: D42384881

Pulled By: hoxyq

fbshipit-source-id: 21fd43391d12722cf707c3cdbbb36f49c036359d

Original: facebook/react-native@f10dd3f
Summary:
Pull Request resolved: facebook/react-native#37513

After the monorepo migration, we started to add license headers to the template file.
This needs to be reverted, I'm doing it here.

Changelog:
[Internal] [Changed] - Do not add Meta's license header to template

Reviewed By: dmytrorykun

Differential Revision: D46070682

fbshipit-source-id: ee071d90c92e32c57698b09298a2f5cf39d3f6d7

Original: facebook/react-native@e93bc9b
Summary:
I was following the upgrade helper from [0.71.7 -> 0.72.0-rc.3](https://react-native-community.github.io/upgrade-helper/?from=0.71.7&to=0.72.0-rc.3) and came across a comment with a URL in the Podfile changes. That comment lead to a 404, so this updates that to the correct URL.

Confirmed this was an issue on the [Roadmap to 0.72.0](reactwg/react-native-releases#54 (comment))

## Changelog:

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

[IOS] [CHANGED] - Message

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests
-->

[IOS] [CHANGED] - fixed URL to New Arch info

Pull Request resolved: facebook/react-native#37535

Test Plan: Only updated a comment, no code changes

Reviewed By: cortinico

Differential Revision: D46145428

Pulled By: cipolleschi

fbshipit-source-id: 600274222725567e1cbae041a3dac9561da15aff

Original: facebook/react-native@6714b99
Summary:
Pull Request resolved: facebook/react-native#37738

Upgrade Prettier to the latest stable version, 2.8.8.

Reviewed By: SamChou19815

Differential Revision: D46403769

fbshipit-source-id: 551d64db0b701a8d3f275900dd8f6324c115a3e6

Original: facebook/react-native@08dc0a6
Summary:
Pull Request resolved: facebook/react-native#37771

While working on debugging tools, I noticed that we ask in every template app to
- Add a "com.facebook.react.devsupport.DevSettingsActivity" activity
- Add the <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>

This is error prone and can be cleanup as we now distribute React Native that is variant aware (debug/release).
So I'm creating a manifest inside `src/debug` that contains those directive so we don't need to ask users
to add them (I'm removing them from the template).

Changelog:
[Internal] [Changed] - Create a Debug manifest inside React Native Android

Reviewed By: cipolleschi

Differential Revision: D46556884

fbshipit-source-id: 10034a6b245bf419dfa663bc998c4d1ad5d24a90

Original: facebook/react-native@f3c8636
…it <AppName>` (#37521)

Summary:
[skip-ci]
I noticed that; when a _new_ RN App is created using RN CLI there is ***NO*** *README* file added to the project.
Having a simple README file explaining what type of project it is, for example how other web projects do it, such as long lived `create-react-app`, now widely used `create-next-app`, etc.

Why not for React Native App then?

This PR; Adds README file to RN Template App ⚡, which should be added to the project when a new project is created using RN CLI.

### Website PR: facebook/react-native-website#3732 🚀😇

bypass-github-export-checks

## Changelog:

[INTERNAL] [ADDED] - Add README to RN Template App ⚡

Pull Request resolved: facebook/react-native#37521

Test Plan: - The README file should be included in the newly created RN App using RN CLI

Reviewed By: NickGerleman

Differential Revision: D46075719

Pulled By: cipolleschi

fbshipit-source-id: efcccc09d72c57a065b36de6e787594082000e15

Original: facebook/react-native@377a8b7
Summary:
Just keeping our Gradle version up to date.

Changelog:
[Internal] [Changed] - Bump Gradle to 8.1.1

Reviewed By: yungsters

Differential Revision: D46769069

fbshipit-source-id: b79ae35473f40e821cf6a1b8e094e33d1b1a44d7

Original: facebook/react-native@84fc79f
Differential Revision: D46802820

fbshipit-source-id: a2737658576bf86f431a7b355d853a529f6a2c34

Original: facebook/react-native@f6f848f
Summary:
Pull Request resolved: facebook/react-native#37709

## Bump minimum Node JS version to 18 via `react-native/package.json#engines`

In facebook/react-native#35443 we bumped up the node version from 16 to 18.

Node 16 [ends maintenance releases on 2023-09-11](https://nodejs.org/en/blog/announcements/nodejs16-eol/), and bumping this minimum will allow other associated Node JS tools (CLI, Metro, Jest) to reduce their support burden.

This follows up by formally making Node 18 the minimum supported version.

**Docs PR:**
facebook/react-native-website#3748

**Changelog:**
[General][Breaking] Bump minimum Node JS version to 18

Reviewed By: yungsters

Differential Revision: D46462639

fbshipit-source-id: d3b607788f596e8b5a9c4a6855d3b2f4bafe9a7a

Original: facebook/react-native@43a6ea9
Summary:
Pull Request resolved: facebook/react-native#37923

Changelog: [Internal]

in this change, i'm looking to make sure our app template will not violate apple best practices and minimize probability of app rejection.

this change entails two guardrails:
- explicitly marking disabling ATS as disabled with a comment. even though this is already the case, this will make it more unlikely someone will override this
- replacing the localhost domain override with the apple provided NSAllowsLocalNetworking key, which is the recommendation

Reviewed By: sammy-SC

Differential Revision: D46707159

fbshipit-source-id: 8fe407d08767269a18fb15c80fdd83a58cf2a4a8

Original: facebook/react-native@3ecbc1d
Summary:
Pull Request resolved: facebook/react-native#38088

For better Kotlin interop we should be using `val` in this interface rather than just `fun`.
This is not a breaking change as Java users can still use `getReactNativeHost()` as before.

Changelog:
[Internal] [Changed] -  Use vals inside ReactApplication

Reviewed By: javache

Differential Revision: D47053030

fbshipit-source-id: 4a7fbc71a76be54e1cf7daef499b9bc3e8fc615a

Original: facebook/react-native@c3f672c
Summary:
Pull Request resolved: facebook/react-native#38141

Bump CLI and Metro versions on main to latest.

Changelog:
[General][Fixed] - Bump CLI to 12.0.0-alpha.6, Metro to 0.76.7

Reviewed By: dmytrorykun

Differential Revision: D47153654

fbshipit-source-id: d9eff64e5539f0e577e059bce836af3c65a4a8c7

Original: facebook/react-native@005d832
…roid` (#37688)

Summary:
Pull Request resolved: facebook/react-native#37688

This moves the `ReactNativeFlipper` classes used to configure Flipper on Android from the template to
a separate Gradle artifact that will be published under the coordinates:
```
com.facebook.react:flipper-integration:0.73.x
```

This reduces the footprint of Flipper on the app template and makes easier for user on 0.73 to migrate
to Kotlin (as they will now have to migrate only 2 files rather than 4).

Changelog:
[Android] [Changed] - Move Flipper integration to a separate Gradle module inside `ReactAndroid`

Reviewed By: huntie

Differential Revision: D46441588

fbshipit-source-id: e197f29b7386b52091b8d38ed09bbd8f74a997df

Original: facebook/react-native@16201f8
… (#38242)

Summary:
Pull Request resolved: facebook/react-native#38242

See proposal: react-native-community/discussions-and-proposals#681

**Removed script files**

I searched GitHub (and specifically `react-native-windows/macos`) to confirm these files are not referenced:

- `scripts/launchPackager.bat`
- `scripts/launchPackager.command`
- `scripts/.packager.env`

Interestingly, React Native CLI refers to a `.packager.env` at a different location (`node_modules/.bin/`), and includes modified copies of `launchPackager.command/bat`. This PR removes duplication with these.

Changelog: [iOS][Breaking] Metro will no longer be started when running builds via Xcode

Reviewed By: cortinico

Differential Revision: D47297469

fbshipit-source-id: 06c3602d58b21ed693c3daa763d99947a70bfc5a

Original: facebook/react-native@dc68457
huntie and others added 27 commits October 11, 2023 08:36
Summary:
#publish-packages-to-npm

Bump all package versions to `0.74.0` (next major release) for `main`, following instructions at https://reactnative.dev/contributing/release-branch-cut-and-rc0#12-bump-minor-version-of-all-monorepo-packages-in-main.

```sh
yarn bump-all-updated-packages --release-branch-cutoff
```

Changelog: [Internal]

Pull Request resolved: facebook/react-native#39764

Test Plan: —

Reviewed By: robhogan

Differential Revision: D49871039

Pulled By: huntie

fbshipit-source-id: f4df6efeae4d8a9209e7aae7b9e6fea3d15793b5

Original: facebook/react-native@f40bb93
Summary:
Currently, the template has a `buildToolsVersion = '34.0.0'` specified in the top level .gradle file but it's not currently using it.

This is causing the build to fallback to the default version provided by AGP which is 33.x
This is also causing the CI to download buildtools 34.0.0 as they're not in the container (causing network flakyness).

I'm also bumping the docker container to v12 as we bumped NDK 26 which is missing in the v11 container.

## Changelog:

[INTERNAL] [FIXED] - Make sure template is consuming the right buildToolsVersion

Pull Request resolved: facebook/react-native#39956

Test Plan: CI should be green

Reviewed By: christophpurrer

Differential Revision: D50019777

Pulled By: cortinico

fbshipit-source-id: a2ab7a7bd7c55624d5c050b45e69086c5f25ba6a

Original: facebook/react-native@a5d5ead
…" (#40854)

Summary:
Pull Request resolved: facebook/react-native#40854

This [commit](facebook/react-native@a5d5ead) seems to break all the Android template tests: [CircleCI](https://app.circleci.com/pipelines/github/facebook/react-native/34139/workflows/b203bbea-d3c4-45aa-9ce1-1ddde6d88bc0).

## Changelog:
[Android][Changed] - revert commit facebook/react-native@a5d5ead

## Facebook:
Original Phabricator Diff: D50019777

Reviewed By: sammy-SC

Differential Revision: D50217952

fbshipit-source-id: d9b93ad72f08cf9f04cacfc04ea9b418f8129079

Original: facebook/react-native@5217890
…(#40938)

Summary:
Currently, the template has a `buildToolsVersion = '34.0.0'` specified in the top level .gradle file but it's not currently using it.

This is causing the build to fallback to the default version provided by AGP which is 33.x
This is also causing the CI to download buildtools 34.0.0 as they're not in the container (causing network flakyness).

## Changelog:

[INTERNAL] [FIXED] - Make sure template is consuming the right buildToolsVersion

Pull Request resolved: facebook/react-native#40938

Test Plan: CI should be green

Reviewed By: cipolleschi

Differential Revision: D50270482

Pulled By: cortinico

fbshipit-source-id: 09fdc66fe24f1cae760d07e4a2f044793a66cafc

Original: facebook/react-native@a030224
Summary:
Pull Request resolved: facebook/react-native#40935

This is scheduled to land in 0.74, so I'm removed the native integration as this is not needed anymore.
The only thing I left is a stub class to ease the migration out of `ReactNativeFlipper`.

Changelog:
[Android] [Removed] - Remove ReactNative/Flipper Integration

Reviewed By: mdvacca, huntie, cipolleschi

Differential Revision: D50259817

fbshipit-source-id: 28427425340896635607202cd78936f6030e78e0

Original: facebook/react-native@171a479
Summary:
Pull Request resolved: facebook/react-native#40929

This diff reduces the footprint that bridgeless is imposing on the new app template. Specifically:
- I've created a `.toReactHost` method that converts a DefaultReactNativeHost to a DefaultReactHost
- I've updated RN Tester to use the same setup as the New App template which reduces code duplication.

I also had to remove a couple of `UnstableReactNativeAPI` as those were bleeding in the new app template.
I don't think we should ask users to opt-in in `UnstableReactNativeAPI` in the New App template itself as
this means that all the apps will get this opt-in.
Instead we should keep it only for specific APIs that we want the users to opt into.

Changelog:
[Internal] [Changed] - Simplify new app template for bridgeless

Reviewed By: cipolleschi, luluwu2032

Differential Revision: D50227693

fbshipit-source-id: e86c54d5156cc27f1f898b43ca89c57d5cf148b8

Original: facebook/react-native@a7f9080
Summary:
Pull Request resolved: facebook/react-native#41002

Following up the deprecation of Flipper in 0.73 and preparing for the removal of Flipper in 0.74, we are removing Flipper integration from the Codebase.

## Changelog:
[iOS][Breaking] - Remove the Flipper integration

Reviewed By: dmytrorykun

Differential Revision: D50321255

fbshipit-source-id: d2f4488ada7acdbd3687f54db4204ba7f09370af

Original: facebook/react-native@899e7cd
…from RNTester (#39540)

Summary:
Pull Request resolved: facebook/react-native#39540

This simplifies the use of Codegen when creating dev builds of `rn-tester` in the monorepo. It now runs from source for this internal scenario, and this package is now built using the shared monorepo build setup.

Changes:
- Migrate `packages/react-native-codegen` to the shared `yarn build` setup.
    - Update package to use `"exports"` field and wrap entry point modules with `babel-register` (NOTE: This is only required for each entry point internally used in the monorepo).
- Fixup small Flow syntax quirks that fail under `hermes-parser`.
- Remove `BuildCodegenCLITask` task from Android build.
- Remove Codegen `build.sh` call from iOS build, use `require.resolve` for `combine-js-to-schema-cli.js` entry point.

Externally significant FYIs:
- `react-native/codegen` is converted to use the `"exports"` field — it should export all `.js` files, as before.
- `codegenPath` is now ignored and marked as deprecated on `ReactExtensions.kt`.

NOTE: TypeScript auto-generation is not yet enabled on this package, since it uses CommonJS `module.exports` syntax (unsupported by `flow-api-translator`).

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D49370200

fbshipit-source-id: 992913155169912ea1a3cb24cb26efbd3f783058

Original: facebook/react-native@4db31a3
…ge build pre-step from RNTester

Differential Revision:
D49370200

Original commit changeset: 992913155169

Original Phabricator Diff: D49370200

fbshipit-source-id: e8232c97c22065fb54ac940ee2351b2155eb51e0

Original: facebook/react-native@d4ad19c
Summary:
Pull Request resolved: facebook/react-native#41551

We have since targeted iOS min SDK 13.4, it's time to move to `arm64`.

Reference: https://developer.apple.com/documentation/bundleresources/information_property_list/uirequireddevicecapabilities?language=objc

Changelog: [iOS][Fixed] Move UIRequiredDeviceCapabilities for RNTester to arm64

Reviewed By: cipolleschi

Differential Revision: D51461103

fbshipit-source-id: 726ca1f37d249092e8f10c2043d0b696bf64aa7d

Original: facebook/react-native@c7bd397
Summary:
Pull Request resolved: facebook/react-native#41621

Currently, if you have a dependency that is alphabetically smaller than `app`, it's evaluation will happen before `app`.
This means that the namespace auto-discovery and the JVM toolchain configuration won't be working and the project will fail to buid.

This fixes it by introducing a root-project Gradle Plugin that takes care of enforcing the evaluation order on the `app` project.

Fixes #41620

Changelog:
[Android] [Fixed] - Fix projects being broken on dependencies starting with `a..`

Reviewed By: huntie

Differential Revision: D51547294

fbshipit-source-id: 65df7149548b7087dd8928e556fb803b3baf7b79

Original: facebook/react-native@5ec2c01
Summary:
Pull Request resolved: facebook/react-native#41748

Bumping to the latest stable of Gradle

Changelog:
[Internal] [Changed] - Gradle to 8.5

Reviewed By: cipolleschi

Differential Revision: D51749139

fbshipit-source-id: 2ee0f9a6c910dd5221f7f63c0c599d4ab181e10a

Original: facebook/react-native@0e9c93c
Summary:
Small edit to point to the newer React Native docs guide for Metro, which includes more clarity on the `metro.config.js` file setup in React Native projects.

Changelog: [Internal]

Pull Request resolved: facebook/react-native#41855

Test Plan: —

Reviewed By: christophpurrer

Differential Revision: D52031862

Pulled By: huntie

fbshipit-source-id: 705418f35e5f6a3eddbec129e283773bb9d0f89c

Original: facebook/react-native@6a52025
Summary:
I believe it's valuable to be able to initialise the React Native template into a mono-repo and have it work with zero updates to the configuration.
In its current form the template's Xcode project makes assumptions on the relative location of the `react-native` package, while it could instead use the `REACT_NATIVE_PATH` variable set in the `scripts/cocoapods/utils.rb` script:

https://github.com/facebook/react-native/blob/2441fa284716ef782ec12dd0c2801548f8c47339/packages/react-native/scripts/cocoapods/utils.rb#L82

via

https://github.com/facebook/react-native/blob/2441fa284716ef782ec12dd0c2801548f8c47339/packages/react-native/template/ios/Podfile#L35

## Changelog:

[IOS] [ADDED] - Add use of the `REACT_NATIVE_PATH` in the "Bundle React Native code and images" shell script build phase. This will help apps initialized into a mono-repo which hoists the `react-native` package.

Pull Request resolved: facebook/react-native#41968

Test Plan: I initialized the React Native template into an NPM workspaces mono-repo and experienced a failure running the script phase. I updated it to the code in this PR, which resolved the issue.

Reviewed By: christophpurrer, cipolleschi

Differential Revision: D52240559

Pulled By: robhogan

fbshipit-source-id: 1c5710c8ffe9d289f32c5ed83cb58ae27f3c931a

Original: facebook/react-native@289e783
Summary:
Bump activesupport to minimum 6.1.7.5 CVE-2023-38037. More details GHSA-cr5q-6q9f-rq6q

Updated the gemfile and then ran `bundle install` at the root

## Changelog:

[IOS] [SECURITY] - Bump activesupport to minimum 6.1.7.5 CVE-2023-38037.

Pull Request resolved: facebook/react-native#42023

Reviewed By: cipolleschi

Differential Revision: D52346223

Pulled By: lunaleaps

fbshipit-source-id: f8141048b68cde9c58eb23ee2d41cb4a6becb6ef

Original: facebook/react-native@07a159f
Summary:
I noticed this comment is still in Java in the Kotlin template. It also doesn't really work anymore since there is no packages variable.

To fix it I completed the comment with all code needed for it to work in kotlin. I think an older version of the template used to be more like:

```kotlin
val packages = PackageList(this).packages
// packages.add(MyReactNativePackage())
return packages
```

But then it requires adding a lint suppress annotation since packages variable can be simplified. I think this is simpler even if it makes the comment a few more lines.

## Changelog:

[GENERAL] [FIXED] - Fix comment about adding packages in android template

Pull Request resolved: facebook/react-native#41856

Test Plan: Tested that uncommenting that code works

Reviewed By: cipolleschi

Differential Revision: D51987483

Pulled By: cortinico

fbshipit-source-id: d0135b5b536960017ccc7b25f92c75b3bd863cd9

Original: facebook/react-native@ac9b87c
Summary:
Building native modules from source, may take a long time. Xcode already helps bring this down, by providing incremental builds, as long as the user doesn't delete their `ios/build` directory. But in some situations, i.e. when iterating the native code of an app or library or when the developer need to delete that `ios/build` directory, it's advantageous to use a compiler cache, such as ccache. This is already outlined in our ["Speeding up your Build phase"](https://reactnative.dev/docs/build-speed#xcode-specific-setup) guide.

But setting up an Xcode project to use Ccache with the correct configuration, isn't trivial in a way that doesn't require symlinking `clang` and `clang++` or passing configuration via environment variables on every `npm run ios` invokation.

This PR takes its inspiration from the existing guide on [setting up Ccache for Xcode](https://reactnative.dev/docs/build-speed#xcode-specific-setup), but applies the build settings only if an installation of `ccache` is detected and the feature is explicitly opted into via an argument to the `react_native_post_install` function or a `USE_CCACHE` environment variable. It uses two shell scripts to wrap the call to `ccache`, which both injects a default `CCACHE_CONFIGPATH` environment variable (i.e. it won't override this if already provided, to allow for customisations on CI), pointing to a `ccache.config` which works well with React Native projects (it has the same values as the guide mentions).

For context, I posted about this change in the ios channel of the contributors Discord server, where I discussed it with cipolleschi and saadnajmi

### Additional output printed when running `pod install`

#### When `ccache_available and ccache_enabled`

```
[Ccache]: Ccache found at /opt/homebrew/bin/ccache
[Ccache]: Setting CC, LD, CXX & LDPLUSPLUS build settings
```

#### When `ccache_available and !ccache_enabled`

```
[Ccache]: Ccache found at /opt/homebrew/bin/ccache
[Ccache]: Pass ':ccache_enabled => true' to 'react_native_post_install' in your Podfile or set environment variable 'USE_CCACHE=1' to increase the speed of subsequent builds
```

#### When `!ccache_available and ccache_enabled`

```
[!] [Ccache]: Install ccache or ensure your neither passing ':ccache_enabled => true' nor setting environment variable 'USE_CCACHE=1'
```

#### Otherwise

If the user doesn't have ccache installed and doesn't explicitly opt into this feature, nothing will be printed.

bypass-github-export-checks

## Changelog:

[IOS] [ADDED] - Added better support for `ccache`, to speed up subsequent builds of native code. After installing `ccache` and running `pod install`, the Xcode project is injected with compiler and linker build settings pointing scripts that loads a default  Ccache configuration and invokes the `ccache` executable.

Pull Request resolved: facebook/react-native#42051

Test Plan:
I've tested this manually - would love some inspiration on how to automate this, if the reviewer deem it needed.
To test this locally:
1. Install Ccache and make sure the `ccache` executable is in your `PATH` (verify by running `ccache --version`)
2. Create a new template app instance and apply the changes of this PR to the `node_modules/react-native` package.
3. Set the `USE_CCACHE` environment variable using `export USE_CCACHE=1`.
4. Run `pod install` in the `ios` directory.
5. Check the stats of Ccache (running `ccache -s`).
6. Run `npm run ios` or build the project from Xcode.
7. Check the Ccache stats again to verify ccache is intercepting compilation ("Cacheable calls" should ideally be 100%).
8. To check the speed gain:
  a. Delete the `ios/builds` directory
  b. Zero out the ccache stats (by running `ccache -z`)
  c. Run `pod install` again (only needed if you ran the initial `pod install` with new architecture enabled `RCT_NEW_ARCH_ENABLED=1`).
  d. Run `npm run ios` or build the project from Xcode.
  e. This last step should be significantly faster and you should see "Hits" under "Local storage" in the ccache stats approach 100%.

Reviewed By: huntie

Differential Revision: D52431507

Pulled By: cipolleschi

fbshipit-source-id: 6cfe39acd6250fae03959f0ee74d1f2fc46b0827

Original: facebook/react-native@e85d51c
Summary:
Pull Request resolved: facebook/react-native#42086

Changelog: [General][Changed] - Update monorepo dependency versions to remove ^

This change will remove the caret for now as we already perform an "align" step everytime we bump a monorepo library. This prevents monorepo library updates to affect existing releases.

The "align" step updates all monorepo libraries to use the updated bumped version: https://fburl.com/code/xfistiph

Reviewed By: huntie

Differential Revision: D52440454

fbshipit-source-id: ff071032f04bc554903dde153c594991163dfe2f

Original: facebook/react-native@6e5bc33
Summary:
Recently inside React Native Community CLI we added bumping Yarn version inside `init` command, more information here: react-native-community/cli#2134. In this Pull Request I added required rules in `.gitignore` for new projects created.

## Changelog:

[GENERAL] [ADDED] - Add Yarn files to `.gitignore` in template

Pull Request resolved: facebook/react-native#42313

Test Plan:
1. Follow [Contributing guide](https://github.com/react-native-community/cli/blob/main/CONTRIBUTING.md) from React Native Community CLI repository to setup locally newest version of CLI.
2. Run this command:

```sh
node /path/to/react-native-cli/packages/cli/build/bin.js init --template path/to/template
```
3. Appropriate should be ignored.

Reviewed By: NickGerleman

Differential Revision: D52907962

Pulled By: cortinico

fbshipit-source-id: f12dce8836e7e94257f8c690434b11227aa46446

Original: facebook/react-native@965f2eb
Summary:
Pull Request resolved: facebook/react-native#42656

I'm bumping the NDK to 26.1. As we already have a bump lined up to 26.0 on main,
it makes sense to go to .1 as it's declared the LTS:
https://github.com/android/ndk/wiki

Changelog:
[Android] [Changed] - Android NDK to 26.1

Reviewed By: NickGerleman

Differential Revision: D53083606

fbshipit-source-id: 12290efcfa8a72ab88c21ffe9507d08d5512d61b

Original: facebook/react-native@5f75e9b
Summary:
Pull Request resolved: facebook/react-native#42675

`ANDROIDLINT` config now has a base setup for RN. This enables it in arc linter, and fixes automatically fixable issues.

Changelog: [Internal]

Reviewed By: joevilches

Differential Revision: D53115471

fbshipit-source-id: 2556c21770f7c7ca54d1bccfff527d39df20101e

Original: facebook/react-native@b5267d9
…702)

Summary:
Cocoapods 1.15 (facebook/react-native#42698) current breaks the build, limit to version >= 1.13 & < 1.15

This is currently broken and affecting users, we'll remove this limit once Cocopods fixes the regression.  It's currently blocking 0.73.3.

## Changelog:
[iOS][Fixed] don't allow cocoapods 1.15.

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

[ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: facebook/react-native#42702

Test Plan:
```
bundle exec pod install
```

Reviewed By: cipolleschi

Differential Revision: D53180111

Pulled By: blakef

fbshipit-source-id: 4c5dd11db6d208e8d71249443a8f85e601913abd

Original: facebook/react-native@3869ae4
Summary:
Pull Request resolved: facebook/react-native#42781

Change in [31cf4c4ead](facebook/react-native@31cf4c4) broke the template for bridgeless as we changed the signature of a method in the header of `RCTAppDelegate`.

This change aligns the API between RCTAppDelegate and the template's AppDelegate

## Changelog:
[iOS][Fixed] - Align the the bundleURL API from `RCTAppDelegate` to template's `AppDelegate`

Reviewed By: cortinico, dmytrorykun

Differential Revision: D53274434

fbshipit-source-id: 25bad702ba05db2e3a6a9449abbda7d8e2fdb8a0

Original: facebook/react-native@ebb55a7
Summary:
Let's keep things up to date.

Changelog:
[Internal] [Changed] - Bump Gradle to 8.6

Reviewed By: cipolleschi

Differential Revision: D53566538

fbshipit-source-id: abbb2a53c944cb5eb4232a70b8af7e34b37fb6a2

Original: facebook/react-native@50bd9e3
Summary:
Pull Request resolved: facebook/react-native#42927

This bumps Kotlin to 1.9.22 which is the latest in OSS and closer to the version we use inside fbsource.

Turns out that Explicit API mode was not enabled correctly, so I had to go over all the Kotlin classes
and correctly set them to `public` if they were intended to be for public consumption.

I updated some of them to `private` or `internal` but otherwise I've defaulted to `public` which is the default
we have right now.

Changelog:
[Android] [Changed] - Kotlin to 1.9.22

Reviewed By: cipolleschi

Differential Revision: D53576844

fbshipit-source-id: dd8b08ce9bf87f738159f60fd850e3e3bc490ebc

Original: facebook/react-native@3c2b2b1
Summary:
This PR makes `__gitignore` file universal for Apple OOT platforms.

## Changelog:

[GENERAL] [CHANGED] - Make template's .gitignore file universal for OOT platforms

Pull Request resolved: facebook/react-native#42963

Test Plan: CI Green

Reviewed By: NickGerleman

Differential Revision: D53674632

Pulled By: yungsters

fbshipit-source-id: cb510d9bd2ee6f1c39b77a842e7947b67def552a

Original: facebook/react-native@c5f48ac
Summary:
Pull Request resolved: facebook/react-native#43135

This change makes the New Architecture the default on both iOS and Android.
This means that new application will be created using the New Architecture by default.

It is still possible to opt out from it.

## Changelog
[General][Changed] - Make the new architecture the default

Reviewed By: cortinico, sammy-SC, dmytrorykun

Differential Revision: D54006751

fbshipit-source-id: bd7de0814925b65ab180105e18c1f6f275ba2672

Original: facebook/react-native@b9f3186
@blakef blakef marked this pull request as ready for review February 29, 2024 17:07
@blakef blakef merged commit f7f527c into react-native-community:main Feb 29, 2024
@blakef blakef deleted the history branch February 29, 2024 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.