Skip to content

Commit e827e9b

Browse files
authored
Bump prettier to version 3.3.3 (#3198)
## Description Bump prettier version to 3.3.3. Required for [this](#3146 (comment)) issue to be resolved. ## Test plan - confirm all CIs are passing - confirm none of the examples are crashing
1 parent 3daca2d commit e827e9b

22 files changed

+126
-69
lines changed

docs/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656
"esbuild": "^0.20.2",
5757
"esbuild-register": "^3.5.0",
5858
"eslint-plugin-mdx": "^2.2.0",
59-
"prettier": "^2.8.4",
59+
"prettier": "^3.3.3",
6060
"typescript": "^4.7.4",
6161
"webpack-cli": "^5.0.1"
6262
},

example/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,9 @@
5555
"babel-jest": "^29.7.0",
5656
"babel-plugin-module-resolver": "^5.0.2",
5757
"eslint": "^7.32.0",
58+
"eslint-plugin-prettier": "^5.2.1",
5859
"jest": "^29.7.0",
59-
"prettier": "2.7.1",
60+
"prettier": "3.3.3",
6061
"react-test-renderer": "18.3.1",
6162
"typescript": "^5.1.3"
6263
},

example/src/release_tests/reanimatedDrawerLayout/index.tsx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ export default function ReanimatedDrawerExample() {
4949
type === DrawerType.FRONT
5050
? DrawerType.BACK
5151
: type === DrawerType.BACK
52-
? DrawerType.SLIDE
53-
: DrawerType.FRONT
52+
? DrawerType.SLIDE
53+
: DrawerType.FRONT
5454
)
5555
);
5656

@@ -61,8 +61,8 @@ export default function ReanimatedDrawerExample() {
6161
lock === DrawerLockMode.UNLOCKED
6262
? DrawerLockMode.LOCKED_CLOSED
6363
: lock === DrawerLockMode.LOCKED_CLOSED
64-
? DrawerLockMode.LOCKED_OPEN
65-
: DrawerLockMode.UNLOCKED
64+
? DrawerLockMode.LOCKED_OPEN
65+
: DrawerLockMode.UNLOCKED
6666
)
6767
);
6868

@@ -94,8 +94,8 @@ export default function ReanimatedDrawerExample() {
9494
{type === DrawerType.FRONT
9595
? 'front'
9696
: type === DrawerType.BACK
97-
? 'back'
98-
: 'slide'}
97+
? 'back'
98+
: 'slide'}
9999
</Text>
100100
</View>
101101
</GestureDetector>
@@ -106,8 +106,8 @@ export default function ReanimatedDrawerExample() {
106106
{lock === DrawerLockMode.UNLOCKED
107107
? 'unlocked'
108108
: lock === DrawerLockMode.LOCKED_OPEN
109-
? 'locked-open'
110-
: 'locked-closed'}
109+
? 'locked-open'
110+
: 'locked-closed'}
111111
</Text>
112112
</View>
113113
</GestureDetector>

example/yarn.lock

Lines changed: 30 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1755,6 +1755,11 @@
17551755
mkdirp "^1.0.4"
17561756
rimraf "^3.0.2"
17571757

1758+
"@pkgr/core@^0.1.0":
1759+
version "0.1.1"
1760+
resolved "https://registry.yarnpkg.com/@pkgr/core/-/core-0.1.1.tgz#1ec17e2edbec25c8306d424ecfbf13c7de1aaa31"
1761+
integrity sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA==
1762+
17581763
"@react-native-async-storage/async-storage@^1.23.1":
17591764
version "1.23.1"
17601765
resolved "https://registry.yarnpkg.com/@react-native-async-storage/async-storage/-/async-storage-1.23.1.tgz#cad3cd4fab7dacfe9838dce6ecb352f79150c883"
@@ -4082,6 +4087,14 @@ eslint-plugin-prettier@^4.2.1:
40824087
dependencies:
40834088
prettier-linter-helpers "^1.0.0"
40844089

4090+
eslint-plugin-prettier@^5.2.1:
4091+
version "5.2.1"
4092+
resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-5.2.1.tgz#d1c8f972d8f60e414c25465c163d16f209411f95"
4093+
integrity sha512-gH3iR3g4JfF+yYPaJYkN7jEl9QbweL/YfkoRlNnuIEHEz1vHVlCmWOS+eGGiRuzHQXdJFCOTxRgvju9b8VUmrw==
4094+
dependencies:
4095+
prettier-linter-helpers "^1.0.0"
4096+
synckit "^0.9.1"
4097+
40854098
eslint-plugin-react-hooks@^4.6.0:
40864099
version "4.6.2"
40874100
resolved "https://registry.yarnpkg.com/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.6.2.tgz#c829eb06c0e6f484b3fbb85a97e57784f328c596"
@@ -7218,10 +7231,10 @@ prettier-linter-helpers@^1.0.0:
72187231
dependencies:
72197232
fast-diff "^1.1.2"
72207233

7221-
prettier@2.7.1:
7222-
version "2.7.1"
7223-
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.7.1.tgz#e235806850d057f97bb08368a4f7d899f7760c64"
7224-
integrity sha512-ujppO+MkdPqoVINuDFDRLClm7D78qbDt0/NR+wp5FqEZOoTNAjPHWj17QRhu7geIHJfcNhRk1XVQmF8Bp3ye+g==
7234+
prettier@3.3.3:
7235+
version "3.3.3"
7236+
resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.3.3.tgz#30c54fe0be0d8d12e6ae61dbb10109ea00d53105"
7237+
integrity sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew==
72257238

72267239
72277240
version "5.6.0"
@@ -8370,6 +8383,14 @@ supports-preserve-symlinks-flag@^1.0.0:
83708383
resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09"
83718384
integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==
83728385

8386+
synckit@^0.9.1:
8387+
version "0.9.2"
8388+
resolved "https://registry.yarnpkg.com/synckit/-/synckit-0.9.2.tgz#a3a935eca7922d48b9e7d6c61822ee6c3ae4ec62"
8389+
integrity sha512-vrozgXDQwYO72vHjUb/HnFbQx1exDjoKzqx23aXEg2a9VIg2TSFZ8FmeZpTjUCFMYw7mpX4BE2SFu8wI7asYsw==
8390+
dependencies:
8391+
"@pkgr/core" "^0.1.0"
8392+
tslib "^2.6.2"
8393+
83738394
table@^6.0.9:
83748395
version "6.8.2"
83758396
resolved "https://registry.yarnpkg.com/table/-/table-6.8.2.tgz#c5504ccf201213fa227248bdc8c5569716ac6c58"
@@ -8557,6 +8578,11 @@ tslib@^2.0.1, tslib@^2.1.0, tslib@^2.4.0:
85578578
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.2.tgz#703ac29425e7b37cd6fd456e92404d46d1f3e4ae"
85588579
integrity sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==
85598580

8581+
tslib@^2.6.2:
8582+
version "2.8.1"
8583+
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.8.1.tgz#612efe4ed235d567e8aba5f2a5fab70280ade83f"
8584+
integrity sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==
8585+
85608586
tsutils@^3.21.0:
85618587
version "3.21.0"
85628588
resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-3.21.0.tgz#b48717d394cea6c1e096983eed58e9d61715b623"

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,11 +87,13 @@
8787
"eslint-config-satya164": "^3.1.8",
8888
"eslint-import-resolver-babel-module": "^5.2.0",
8989
"eslint-plugin-jest": "^26.0.0",
90+
"eslint-plugin-prettier": "^5.2.1",
91+
"expo": "^35.0.1",
9092
"husky": "^8.0.1",
9193
"jest": "^28.1.0",
9294
"lint-staged": "^12.3.2",
9395
"madge": "^6.1.0",
94-
"prettier": "2.7.1",
96+
"prettier": "3.3.3",
9597
"react": "18.2.0",
9698
"react-native": "0.74.3",
9799
"react-native-builder-bob": "^0.17.1",

src/ActionType.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ export const ActionType = {
66
} as const;
77

88
// eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value
9-
export type ActionType = typeof ActionType[keyof typeof ActionType];
9+
export type ActionType = (typeof ActionType)[keyof typeof ActionType];

src/Directions.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export const DiagonalDirections = {
2020
} as const;
2121

2222
// eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value
23-
export type Directions = typeof Directions[keyof typeof Directions];
23+
export type Directions = (typeof Directions)[keyof typeof Directions];
2424
// eslint-disable-next-line @typescript-eslint/no-redeclare
2525
export type DiagonalDirections =
26-
typeof DiagonalDirections[keyof typeof DiagonalDirections];
26+
(typeof DiagonalDirections)[keyof typeof DiagonalDirections];

src/State.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ export const State = {
1010
} as const;
1111

1212
// eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value
13-
export type State = typeof State[keyof typeof State];
13+
export type State = (typeof State)[keyof typeof State];

src/TouchEventType.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,5 @@ export const TouchEventType = {
77
} as const;
88

99
// eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value
10-
export type TouchEventType = typeof TouchEventType[keyof typeof TouchEventType];
10+
export type TouchEventType =
11+
(typeof TouchEventType)[keyof typeof TouchEventType];

src/components/Pressable/Pressable.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,15 @@ export default function Pressable(props: PressableProps) {
5858

5959
const normalizedHitSlop: Insets = useMemo(
6060
() =>
61-
typeof hitSlop === 'number' ? numberAsInset(hitSlop) : hitSlop ?? {},
61+
typeof hitSlop === 'number' ? numberAsInset(hitSlop) : (hitSlop ?? {}),
6262
[hitSlop]
6363
);
6464

6565
const normalizedPressRetentionOffset: Insets = useMemo(
6666
() =>
6767
typeof pressRetentionOffset === 'number'
6868
? numberAsInset(pressRetentionOffset)
69-
: pressRetentionOffset ?? {},
69+
: (pressRetentionOffset ?? {}),
7070
[pressRetentionOffset]
7171
);
7272

0 commit comments

Comments
 (0)