Skip to content

Commit 5532c57

Browse files
committed
Merge commit '1c51d6684b50f21f769ea51a0613967c639f5106'
1 parent 721a5aa commit 5532c57

File tree

4,546 files changed

+254532
-139413
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

4,546 files changed

+254532
-139413
lines changed

.eslintignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ packages/*/dist
1313
packages/*/types_generated
1414
packages/debugger-frontend/dist/**/*
1515
packages/react-native-codegen/lib
16-
tools/eslint/rules/sort-imports.js
1716
**/Pods/*
1817
**/*.macos.js
1918
**/*.windows.js

.eslintrc.js

Lines changed: 42 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,18 @@
44
* This source code is licensed under the MIT license found in the
55
* LICENSE file in the root directory of this source tree.
66
*
7+
* @noflow
78
* @format
89
*/
910

1011
'use strict';
1112

12-
const path = require('node:path');
13-
14-
require('eslint-plugin-lint').load(path.join(__dirname, 'tools/eslint/rules'));
15-
1613
module.exports = {
1714
root: true,
1815

1916
extends: ['@react-native'],
2017

21-
plugins: ['@react-native/eslint-plugin-specs', 'lint'],
18+
plugins: ['@react-native/monorepo', '@react-native/specs'],
2219

2320
overrides: [
2421
// overriding the JS config from @react-native/eslint-config to ensure
@@ -27,22 +24,34 @@ module.exports = {
2724
files: ['*.js', '*.js.flow', '*.jsx'],
2825
parser: 'hermes-eslint',
2926
rules: {
27+
'@react-native/monorepo/sort-imports': 'warn',
28+
'eslint-comments/no-unlimited-disable': 'off',
29+
'ft-flow/require-valid-file-annotation': ['error', 'always'],
30+
'no-extra-boolean-cast': 'off',
31+
'no-void': 'off',
3032
// These rules are not required with hermes-eslint
31-
'ft-flow/define-flow-type': 0,
32-
'ft-flow/use-flow-type': 0,
33-
'lint/sort-imports': 1,
34-
// flow handles this check for us, so it's not required
35-
'no-undef': 0,
33+
'ft-flow/define-flow-type': 'off',
34+
'ft-flow/use-flow-type': 'off',
35+
// Flow handles these checks for us, so they aren't required
36+
'no-undef': 'off',
37+
'no-unreachable': 'off',
38+
},
39+
},
40+
{
41+
files: ['*.js', '*.jsx', '*.ts', '*.tsx'],
42+
rules: {
43+
'@react-native/no-deep-imports': 'off',
3644
},
3745
},
3846
{
3947
files: [
40-
'./packages/react-native/**/*.{js,flow}',
48+
'./packages/react-native/Libraries/**/*.{js,flow}',
49+
'./packages/react-native/src/**/*.{js,flow}',
4150
'./packages/assets/registry.js',
4251
],
4352
parser: 'hermes-eslint',
4453
rules: {
45-
'lint/no-commonjs-exports': 1,
54+
'@react-native/monorepo/no-commonjs-exports': 'warn',
4655
},
4756
},
4857
{
@@ -52,15 +61,17 @@ module.exports = {
5261
{
5362
files: ['package.json'],
5463
rules: {
55-
'lint/react-native-manifest': 2,
64+
'@react-native/monorepo/react-native-manifest': 'error',
5665
},
5766
},
5867
{
59-
files: ['flow-typed/**/*.js'],
68+
files: ['flow-typed/**/*.js', 'packages/react-native/flow/**/*'],
6069
rules: {
61-
'lint/valid-flow-typed-signature': 2,
62-
'no-unused-vars': 0,
63-
quotes: 0,
70+
'@react-native/monorepo/valid-flow-typed-signature': 'error',
71+
'ft-flow/require-valid-file-annotation': 'off',
72+
'no-shadow': 'off',
73+
'no-unused-vars': 'off',
74+
quotes: 'off',
6475
},
6576
},
6677
{
@@ -69,11 +80,14 @@ module.exports = {
6980
'packages/react-native/src/**/*.js',
7081
],
7182
rules: {
72-
'@react-native/platform-colors': 2,
73-
'@react-native/specs/react-native-modules': 2,
74-
'lint/no-haste-imports': 2,
75-
'lint/no-react-native-imports': 2,
76-
'lint/require-extends-error': 2,
83+
'@react-native/monorepo/no-haste-imports': 'error',
84+
'@react-native/monorepo/no-react-default-imports': 'error',
85+
'@react-native/monorepo/no-react-named-type-imports': 'error',
86+
'@react-native/monorepo/no-react-native-imports': 'error',
87+
'@react-native/monorepo/no-react-node-imports': 'error',
88+
'@react-native/monorepo/require-extends-error': 'error',
89+
'@react-native/platform-colors': 'error',
90+
'@react-native/specs/react-native-modules': 'error',
7791
},
7892
},
7993
{
@@ -124,5 +138,11 @@ module.exports = {
124138
],
125139
},
126140
},
141+
{
142+
files: ['**/__tests__/**'],
143+
rules: {
144+
'@react-native/monorepo/no-react-native-imports': 'off',
145+
},
146+
},
127147
],
128148
};

.flowconfig

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,14 @@
22
; Ignore build cache folder
33
<PROJECT_ROOT>/packages/react-native/sdks/.*
44

5+
; Ignore fb_internal modules
6+
<PROJECT_ROOT>/packages/react-native/src/fb_internal/.*
7+
58
; Ignore the codegen e2e tests
69
<PROJECT_ROOT>/packages/react-native-codegen/e2e/__test_fixtures__/modules/NativeEnumTurboModule.js
710

811
; Ignore the Dangerfile
9-
<PROJECT_ROOT>/packages/react-native-bots/dangerfile.js
12+
<PROJECT_ROOT>/private/react-native-bots/dangerfile.js
1013

1114
; Ignore "BUCK" generated dirs
1215
<PROJECT_ROOT>/\.buckd/
@@ -24,7 +27,7 @@
2427
<PROJECT_ROOT>/packages/.*/dist
2528

2629
; helloworld
27-
<PROJECT_ROOT>/packages/helloworld/ios/Pods/
30+
<PROJECT_ROOT>/private/helloworld/ios/Pods/
2831

2932
; Ignore rn-tester Pods
3033
<PROJECT_ROOT>/packages/rn-tester/Pods/
@@ -41,11 +44,12 @@
4144
flow-typed/
4245
packages/react-native/interface.js
4346
packages/react-native/flow/
44-
packages/react-native/src/types/
4547

4648
[options]
4749
enums=true
50+
experimental.pattern_matching=true
4851
casting_syntax=both
52+
component_syntax=true
4953

5054
emoji=true
5155

@@ -67,6 +71,10 @@ module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/packages/react-nat
6771
module.name_mapper='^@react-native/dev-middleware$' -> '<PROJECT_ROOT>/packages/dev-middleware'
6872
module.name_mapper='^@?[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\|xml\)$' -> '<PROJECT_ROOT>/packages/react-native/Libraries/Image/RelativeImageStub'
6973

74+
module.system.haste.module_ref_prefix=m#
75+
76+
react.runtime=automatic
77+
7078
suppress_type=$FlowIssue
7179
suppress_type=$FlowFixMe
7280
suppress_type=$FlowFixMeProps
@@ -96,4 +104,4 @@ untyped-import
96104
untyped-type-import
97105

98106
[version]
99-
^0.262.0
107+
^0.275.0

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
# Ensure scripts always have Unix newlines, even on Windows.
22
*.command text eol=lf
33
*.sh text eol=lf
4+
*.js.flow linguist-language=JavaScript

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ body:
1919
* Please [search for similar issues](https://github.com/facebook/react-native/issues) in our issue tracker.
2020
2121
Make sure that your issue:
22-
* Have a **valid reproducer** (either a [Expo Snack](https://snack.expo.dev/) or a [empty project from template](https://github.com/react-native-community/reproducer-react-native).
22+
* Have a **valid reproducer** (See [How to report a bug](https://reactnative.dev/contributing/how-to-report-a-bug)).
2323
* Is tested against the [**latest stable**](https://github.com/facebook/react-native/releases/) of React Native.
2424
25-
Due to the extreme number of bugs we receive, we will be looking **ONLY** into issues with a reproducer, and on [supported versions](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported) of React Native.
25+
🚨 IMPORTANT: Due to the extreme number of bugs we receive, issues **without a reproducer** or for an [**unsupported versions**](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported) of React Native **will be closed**.
2626
- type: textarea
2727
id: description
2828
attributes:
@@ -83,7 +83,7 @@ body:
8383
path: /bin/zsh
8484
Binaries:
8585
Node: ...
86-
version: 18.14.0
86+
version: 22.14.0
8787
...
8888
render: text
8989
validations:
@@ -109,8 +109,8 @@ body:
109109
- type: input
110110
id: reproducer
111111
attributes:
112-
label: Reproducer
113-
description: A link to a Expo Snack or a public repository that reproduces this bug, using [this template](https://github.com/react-native-community/reproducer-react-native). Reproducers are **mandatory**.
112+
label: MANDATORY Reproducer
113+
description: A link to either a failing RNTesterPlayground.js file, an Expo Snack or a public repository from [this template](https://github.com/react-native-community/reproducer-react-native) that reproduces this bug. Reproducers are **mandatory**, issues without a reproducer will be closed.
114114
placeholder: "https://github.com/<myuser>/<myreproducer>"
115115
validations:
116116
required: true

.github/ISSUE_TEMPLATE/debugger_bug_report.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ body:
6262
path: /bin/zsh
6363
Binaries:
6464
Node: ...
65-
version: 18.14.0
65+
version: 22.14.0
6666
...
6767
render: text
6868
validations:

.github/ISSUE_TEMPLATE/new_architecture_bug_report.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ body:
1616
Do not attempt to open a bug in this category if you're not using the New Architecture as your bug will be closed.
1717
1818
Make sure that your issue:
19-
* Have a **valid reproducer** (either a [Expo Snack](https://snack.expo.dev/) or a [empty project from template](https://github.com/react-native-community/reproducer-react-native).
19+
* Have a **valid reproducer** (See [How to report a bug](https://reactnative.dev/contributing/how-to-report-a-bug)).
2020
* Is tested against the [**latest stable**](https://github.com/facebook/react-native/releases/) of React Native.
2121
22-
Due to the extreme number of bugs we receive, we will be looking **ONLY** into issues with a reproducer, and on [supported versions](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported) of React Native.
22+
🚨 IMPORTANT: Due to the extreme number of bugs we receive, issues **without a reproducer** or for an [**unsupported versions**](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported) of React Native **will be closed**.
2323
- type: textarea
2424
id: description
2525
attributes:
@@ -95,7 +95,7 @@ body:
9595
path: /bin/zsh
9696
Binaries:
9797
Node: ...
98-
version: 18.14.0
98+
version: 22.14.0
9999
...
100100
render: text
101101
validations:
@@ -121,8 +121,8 @@ body:
121121
- type: input
122122
id: reproducer
123123
attributes:
124-
label: Reproducer
125-
description: A link to a Expo Snack or a public repository that reproduces this bug, using [this template](https://github.com/react-native-community/reproducer-react-native). Reproducers are **mandatory**.
124+
label: MANDATORY Reproducer
125+
description: A link to either a failing RNTesterPlayground.js file, an Expo Snack or a public repository from [this template](https://github.com/react-native-community/reproducer-react-native) that reproduces this bug. Reproducers are **mandatory**, issues without a reproducer will be closed.
126126
placeholder: "https://github.com/<myuser>/<myreproducer>"
127127
validations:
128128
required: true

.github/actions/build-android/action.yml

Lines changed: 4 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -86,27 +86,13 @@ runs:
8686
if: ${{ always() }}
8787
uses: actions/[email protected]
8888
with:
89-
name: rntester-hermes-debug
90-
path: packages/rn-tester/android/app/build/outputs/apk/hermes/debug/
89+
name: rntester-debug
90+
path: packages/rn-tester/android/app/build/outputs/apk/debug/
9191
compression-level: 0
9292
- name: Upload RNTester APK - hermes-release
9393
if: ${{ always() }}
9494
uses: actions/[email protected]
9595
with:
96-
name: rntester-hermes-release
97-
path: packages/rn-tester/android/app/build/outputs/apk/hermes/release/
98-
compression-level: 0
99-
- name: Upload RNTester APK - jsc-debug
100-
if: ${{ always() }}
101-
uses: actions/[email protected]
102-
with:
103-
name: rntester-jsc-debug
104-
path: packages/rn-tester/android/app/build/outputs/apk/jsc/debug/
105-
compression-level: 0
106-
- name: Upload RNTester APK - jsc-release
107-
if: ${{ always() }}
108-
uses: actions/[email protected]
109-
with:
110-
name: rntester-jsc-release
111-
path: packages/rn-tester/android/app/build/outputs/apk/jsc/release/
96+
name: rntester-release
97+
path: packages/rn-tester/android/app/build/outputs/apk/release/
11298
compression-level: 0

.github/actions/build-hermesc-apple/action.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ inputs:
1010
runs:
1111
using: composite
1212
steps:
13+
- name: Setup xcode
14+
uses: ./.github/actions/setup-xcode
1315
- name: Restore Hermes workspace
1416
uses: ./.github/actions/restore-hermes-workspace
1517
- name: Hermes apple cache

.github/actions/build-hermesc-linux/action.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,12 @@ runs:
1414
shell: bash
1515
run: |
1616
sudo apt update
17-
sudo apt install -y git openssh-client cmake build-essential \
17+
sudo apt install -y git openssh-client build-essential \
1818
libreadline-dev libicu-dev jq zip python3
19+
20+
# Install cmake 3.28.3-1build7
21+
sudo apt-get install cmake=3.28.3-1build7
22+
sudo ln -sf /usr/bin/cmake /usr/local/bin/cmake
1923
- name: Restore Hermes workspace
2024
uses: ./.github/actions/restore-hermes-workspace
2125
- name: Linux cache

0 commit comments

Comments
 (0)