Skip to content

Commit 314f049

Browse files
authored
chore: Upgrade React Native to 0.73.6 (#5621)
1 parent 302511f commit 314f049

File tree

227 files changed

+11745
-18004
lines changed

Some content is hidden

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

227 files changed

+11745
-18004
lines changed

.buckconfig

-6
This file was deleted.

.circleci/config.yml

+23-35
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
11
defaults: &defaults
22
working_directory: ~/repo
33

4+
android-executor: &android-executor
5+
executor:
6+
name: android/android-machine
7+
resource-class: large
8+
tag: 2024.01.1
9+
410
orbs:
5-
android: circleci/android@2.1.2
11+
android: circleci/android@2.5.0
612

713
macos: &macos
814
macos:
@@ -87,7 +93,6 @@ commands:
8793
- run:
8894
name: Install ruby
8995
command: |
90-
echo "ruby-2.7.7" > ~/.ruby-version
9196
if [ -d ~/.rbenv/versions/2.7.7 ]; then
9297
echo "Ruby already installed"
9398
else
@@ -139,11 +144,11 @@ commands:
139144
name: Configure Gradle
140145
command: |
141146
echo -e "" > ./gradle.properties
142-
# echo -e "android.enableAapt2=false" >> ./gradle.properties
143147
echo -e "android.useAndroidX=true" >> ./gradle.properties
144148
echo -e "android.enableJetifier=true" >> ./gradle.properties
149+
echo -e "reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64" >> ./gradle.properties
145150
echo -e "newArchEnabled=false" >> ./gradle.properties
146-
echo -e "FLIPPER_VERSION=0.125.0" >> ./gradle.properties
151+
echo -e "hermesEnabled=true" >> ./gradle.properties
147152
echo -e "VERSIONCODE=$CIRCLE_BUILD_NUM" >> ./gradle.properties
148153
149154
if [[ $CIRCLE_JOB == "android-build-official" ]]; then
@@ -188,23 +193,15 @@ commands:
188193
working_directory: android
189194

190195
- run:
191-
name: Upload sourcemaps to Bugsnag
196+
name: Upload sourcemaps/NDK symbols to Bugsnag
192197
command: |
193198
if [[ $CIRCLE_JOB == "android-build-official" ]]; then
194-
npx bugsnag-source-maps upload-react-native \
195-
--api-key=$BUGSNAG_KEY_OFFICIAL \
196-
--app-version-code=$CIRCLE_BUILD_NUM \
197-
--platform android \
198-
--source-map=android/app/build/generated/sourcemaps/react/officialPlay/release/app.bundle.map \
199-
--bundle android/app/build/generated/assets/react/officialPlay/release/app.bundle
199+
yarn bugsnag:upload-android --variant officialPlayRelease
200+
yarn bugsnag-cli upload android-aab android/app/build/outputs/bundle/officialPlayRelease/app-official-play-release.aab
200201
fi
201202
if [[ $CIRCLE_JOB == "android-build-experimental" || "android-automatic-build-experimental" ]]; then
202-
npx bugsnag-source-maps upload-react-native \
203-
--api-key=$BUGSNAG_KEY \
204-
--app-version-code=$CIRCLE_BUILD_NUM \
205-
--platform android \
206-
--source-map=android/app/build/generated/sourcemaps/react/experimentalPlay/release/app.bundle.map \
207-
--bundle android/app/build/generated/assets/react/experimentalPlay/release/app.bundle
203+
yarn bugsnag:upload-android --variant experimentalPlayRelease
204+
yarn bugsnag-cli upload android-aab android/app/build/outputs/bundle/experimentalPlayRelease/app-experimental-play-release.aab
208205
fi
209206
210207
- store_artifacts:
@@ -384,7 +381,7 @@ jobs:
384381
lint-testunit:
385382
<<: *defaults
386383
docker:
387-
- image: cimg/node:16.14
384+
- image: cimg/node:lts
388385
resource_class: large
389386
environment:
390387
CODECOV_TOKEN: caa771ab-3d45-4756-8e2a-e1f25996fef6
@@ -416,35 +413,29 @@ jobs:
416413
# Android builds
417414
android-build-experimental:
418415
<<: *defaults
419-
docker:
420-
- image: cimg/android:2023.11-node
416+
<<: *android-executor
421417
environment:
422418
<<: *android-env
423419
<<: *bash-env
424-
resource_class: large
425420
steps:
426421
- android-build
427422

428423
# Android automatic builds
429424
android-automatic-build-experimental:
430425
<<: *defaults
431-
docker:
432-
- image: cimg/android:2023.11-node
426+
<<: *android-executor
433427
environment:
434428
<<: *android-env
435429
<<: *bash-env
436-
resource_class: large
437430
steps:
438431
- android-build
439432

440433
android-build-official:
441434
<<: *defaults
442-
docker:
443-
- image: cimg/android:2023.11-node
435+
<<: *android-executor
444436
environment:
445437
<<: *android-env
446438
<<: *bash-env
447-
resource_class: large
448439
steps:
449440
- android-build
450441

@@ -483,10 +474,7 @@ jobs:
483474

484475
e2e-build-android:
485476
<<: *defaults
486-
executor:
487-
name: android/android-machine
488-
resource-class: large
489-
tag: 2022.12.1
477+
<<: *android-executor
490478
environment:
491479
<<: *android-env
492480
steps:
@@ -499,11 +487,11 @@ jobs:
499487
name: Configure Gradle
500488
command: |
501489
echo -e "" > ./gradle.properties
502-
# echo -e "android.enableAapt2=false" >> ./gradle.properties
503490
echo -e "android.useAndroidX=true" >> ./gradle.properties
504491
echo -e "android.enableJetifier=true" >> ./gradle.properties
492+
echo -e "reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64" >> ./gradle.properties
505493
echo -e "newArchEnabled=false" >> ./gradle.properties
506-
echo -e "FLIPPER_VERSION=0.125.0" >> ./gradle.properties
494+
echo -e "hermesEnabled=true" >> ./gradle.properties
507495
echo -e "VERSIONCODE=$CIRCLE_BUILD_NUM" >> ./gradle.properties
508496
echo -e "APPLICATION_ID=chat.rocket.reactnative" >> ./gradle.properties
509497
echo -e "BugsnagAPIKey=$BUGSNAG_KEY" >> ./gradle.properties
@@ -532,8 +520,8 @@ jobs:
532520
<<: *defaults
533521
executor:
534522
name: android/android-machine
535-
resource-class: large
536-
tag: 2022.12.1
523+
resource-class: xlarge
524+
tag: 2024.01.1
537525
parallelism: 4
538526
steps:
539527
- checkout

.detoxrc.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ module.exports = {
99
},
1010
artifacts: {
1111
plugins: {
12-
screenshot: process.env.CI ? undefined : 'failing',
13-
video: process.env.CI ? undefined : 'failing',
12+
screenshot: 'failing',
13+
video: 'failing',
1414
uiHierarchy: process.env.CI ? undefined : 'enabled'
1515
}
1616
},

.eslintrc.js

+7-4
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ module.exports = {
77
}
88
},
99
parser: '@babel/eslint-parser',
10-
extends: ['@rocket.chat/eslint-config', 'prettier'],
10+
extends: ['plugin:jest/recommended', '@rocket.chat/eslint-config', 'prettier'],
1111
parserOptions: {
1212
sourceType: 'module',
1313
ecmaVersion: 2017,
@@ -17,14 +17,15 @@ module.exports = {
1717
legacyDecorators: true
1818
}
1919
},
20-
plugins: ['react', 'jsx-a11y', 'import', 'react-native', '@babel', 'jest', 'react-hooks'],
20+
plugins: ['react', 'jsx-a11y', 'import', 'react-native', '@babel', 'react-hooks', 'jest'],
2121
env: {
2222
browser: true,
2323
commonjs: true,
2424
es6: true,
2525
node: true,
2626
jquery: true,
2727
mocha: true,
28+
jest: true,
2829
'jest/globals': true
2930
},
3031
rules: {
@@ -225,7 +226,8 @@ module.exports = {
225226
'new-cap': 'off',
226227
'lines-between-class-members': 'off',
227228
'react-hooks/rules-of-hooks': 'error',
228-
'react-hooks/exhaustive-deps': 'warn'
229+
'react-hooks/exhaustive-deps': 'warn',
230+
'jest/no-conditional-expect': 'off'
229231
},
230232
globals: {
231233
JSX: true
@@ -241,7 +243,8 @@ module.exports = {
241243
{
242244
files: ['e2e/**'],
243245
rules: {
244-
'no-await-in-loop': 0
246+
'no-await-in-loop': 0,
247+
'jest/expect-expect': 'off'
245248
}
246249
}
247250
]

.gitignore

+12-8
Original file line numberDiff line numberDiff line change
@@ -20,33 +20,37 @@ DerivedData
2020
*.hmap
2121
*.ipa
2222
*.xcuserstate
23+
ios/.xcode.env.local
2324
project.xcworkspace
2425
*.mobileprovision
2526
ios/Pods/
2627
/vendor/bundle/
2728

29+
# Temporary files created by Metro to check the health of the file watcher
30+
.metro-health-check*
31+
32+
# testing
33+
/coverage
34+
2835
# Android/IntelliJ
2936
#
3037
build/
3138
.idea
3239
.gradle
3340
local.properties
3441
*.iml
42+
*.hprof
43+
.cxx/
44+
*.keystore
45+
*.jks
46+
!debug.keystore
3547

3648
# node.js
3749
#
3850
node_modules/
3951
npm-debug.log
4052
yarn-error.log
4153

42-
coverage/
43-
44-
# BUCK
45-
buck-out/
46-
\.buckd/
47-
*.keystore
48-
*.jks
49-
5054
# fastlane
5155
#
5256
# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the

.ruby-version

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.7.7
1+
2.7.7

.storybook/index.js

-19
This file was deleted.

.storybook/index.ts

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import AsyncStorage from '@react-native-async-storage/async-storage';
2+
import { view } from './storybook.requires';
3+
import RNBootSplash from 'react-native-bootsplash';
4+
5+
const StorybookUIRoot = view.getStorybookUI({
6+
storage: {
7+
getItem: AsyncStorage.getItem,
8+
setItem: AsyncStorage.setItem,
9+
},
10+
});
11+
12+
RNBootSplash.hide();
13+
14+
export default StorybookUIRoot;

.storybook/main.js

-4
This file was deleted.

.storybook/main.ts

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
import { StorybookConfig } from '@storybook/react-native';
2+
3+
const main: StorybookConfig = {
4+
stories: ['../app/**/*.stories.?(ts|tsx|js|jsx)'],
5+
addons: [],
6+
};
7+
8+
export default main;

.storybook/preview.js

-40
This file was deleted.

0 commit comments

Comments
 (0)