Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c7775ed

Browse files
authored
Upgrade to Expo SDK 47 (#360)
* fix(runtime): drop sdkVersion from app.json * refactor(runtime): upgrade to Expo SDK 47 beta * refactor(runtime): update patches to used package versions * refactor(snack-content): upgrade to Expo SDK 47 beta * refactor(snack-sdk): upgrade bundled native modules fixture to Expo SDK 47 beta * test(snack-sdk): update the tests for Expo SDK 47 beta * docs(snack-sdk): add changelog entries * refactor(website): upgrade to Expo SDK 47 beta * fix(runtime): use event subscriptions in app * fix(runtime: change barcode scanned types to match code * test(snackager): update to Expo SDK 47 beta * docs: update changelogs to include pr * fix(runtime): work around reanimated issue #3437 See: software-mansion/react-native-reanimated#3437 See: https://github.com/expo/expo/pull/19305\#issuecomment-1263114915 * fix(runtime): fix deployment script removing sdkVersion usage * refactor(runtime): update dependencies for SDK 47 stable * refactor(snack-sdk): upgrade bundled native modules fixture to Expo SDK 47 stable * test(snack-sdk): update the tests for Expo SDK 47 stale
1 parent c107e34 commit c7775ed

24 files changed

Lines changed: 1003 additions & 958 deletions

File tree

docs/expo-sdk-upgrade.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ Update the Snack runtime (managed Expo app), snack-sdk and website to the latest
2626
### runtime
2727

2828
- Either run `expo update <version>` or upgrade the dependencies in `package.json` to match those in `bundledNativeModules.json`.
29-
- Set `expo.sdkVersion` in `app.json` to the new version.
3029
- Update the patched packages in `./patches`.
3130
- Update any default project files to match the template in `expo/templates/expo-template-blank`.
3231
- Update the files in `./web` to match the latest expo-cli defaults (`expo customize:web`).
@@ -101,7 +100,7 @@ The Expo documentation contains excellent examples for verifying Snack. The easi
101100

102101
## Pre-release snack-sdk
103102

104-
To enable partners to use the new Expo SDK, snack-sdk can be released to the `next` channel.
103+
To enable partners to use the new Expo SDK, snack-sdk can be released to the `next` channel.
105104

106105
- Update the version in `package.json`. Ex. "3.2.1-rc.0"
107106
- `yarn build`

packages/snack-content/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,12 @@
44

55
### 🛠 Breaking changes
66

7+
- Dropped Expo SDK 44 ([#360](https://github.com/expo/snack/pull/360) by [@bycedric](https://github.com/byCedric))
8+
79
### 🎉 New features
810

11+
- Upgrade to Expo SDK 47 ([#360](https://github.com/expo/snack/pull/360) by [@bycedric](https://github.com/byCedric))
12+
913
## 1.2.0 - 2022-08-03
1014

1115
### 🎉 New features

packages/snack-content/src/defaults.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ import { SDKVersion } from './types';
33
export const defaultSdkVersion: SDKVersion = '46.0.0';
44

55
// Mostly used for tests
6-
export const oldestSdkVersion: SDKVersion = '44.0.0';
7-
export const newestSdkVersion: SDKVersion = '46.0.0';
6+
export const oldestSdkVersion: SDKVersion = '45.0.0';
7+
export const newestSdkVersion: SDKVersion = '47.0.0';

packages/snack-content/src/sdks/index.ts

Lines changed: 20 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ const assets = {
77
};
88

99
const sdks: { [version: string]: SDKSpec } = {
10-
'44.0.0': {
11-
version: '^44.0.0',
10+
'45.0.0': {
11+
version: '^45.0.0',
1212
coreModules: {
1313
...assets,
14-
expo: '~44.0.0',
14+
expo: '~45.0.0',
1515
react: '17.0.1',
1616
'react-dom': '*',
17-
'react-native': '0.64.3',
17+
'react-native': '0.68.2',
1818
'react-native-web': '*',
1919
},
2020
bundledModules: {
@@ -33,17 +33,22 @@ const sdks: { [version: string]: SDKSpec } = {
3333
'Async Storage has moved to new organization: https://github.com/react-native-async-storage/async-storage',
3434
'expo-permissions':
3535
'Use permissions getters and requesters in specific modules instead, such as MediaLibrary.getPermissionsAsync() and MediaLibrary.requestPermissionsAsync().',
36+
'expo-app-loading':
37+
'Use expo-splash-screen directly instead: SplashScreen.preventAutoHideAsync() and SplashScreen.hideAsync().',
3638
},
3739
},
38-
'45.0.0': {
39-
version: '^45.0.0',
40+
'46.0.0': {
41+
version: '^46.0.0',
4042
coreModules: {
4143
...assets,
42-
expo: '~45.0.0',
43-
react: '17.0.1',
44+
expo: '~46.0.0',
45+
react: '18.0.0',
4446
'react-dom': '*',
45-
'react-native': '0.68.2',
47+
'react-native': '0.69.3',
4648
'react-native-web': '*',
49+
// Used by @shopify/react-native-skia, on web only
50+
// See runtime/src/NativeModules/ReactNativeSkia.tsx for more info
51+
'@shopify/react-native-skia/lib/module/web': '*',
4752
},
4853
bundledModules: {
4954
'expo-asset': '*',
@@ -65,14 +70,14 @@ const sdks: { [version: string]: SDKSpec } = {
6570
'Use expo-splash-screen directly instead: SplashScreen.preventAutoHideAsync() and SplashScreen.hideAsync().',
6671
},
6772
},
68-
'46.0.0': {
69-
version: '^46.0.0',
73+
'47.0.0': {
74+
version: '^47.0.0',
7075
coreModules: {
7176
...assets,
72-
expo: '~46.0.0',
73-
react: '18.0.0',
77+
expo: '~47.0.0-beta.3',
78+
react: '18.1.0',
7479
'react-dom': '*',
75-
'react-native': '0.69.3',
80+
'react-native': '0.70.4',
7681
'react-native-web': '*',
7782
// Used by @shopify/react-native-skia, on web only
7883
// See runtime/src/NativeModules/ReactNativeSkia.tsx for more info
@@ -89,14 +94,7 @@ const sdks: { [version: string]: SDKSpec } = {
8994
'expo-updates': '*',
9095
'@react-native-async-storage/async-storage': '*',
9196
},
92-
deprecatedModules: {
93-
'@react-native-community/async-storage':
94-
'Async Storage has moved to new organization: https://github.com/react-native-async-storage/async-storage',
95-
'expo-permissions':
96-
'Use permissions getters and requesters in specific modules instead, such as MediaLibrary.getPermissionsAsync() and MediaLibrary.requestPermissionsAsync().',
97-
'expo-app-loading':
98-
'Use expo-splash-screen directly instead: SplashScreen.preventAutoHideAsync() and SplashScreen.hideAsync().',
99-
},
97+
deprecatedModules: {},
10098
},
10199
};
102100

packages/snack-content/src/sdks/types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* Version of the Expo SDK to use (e.g. "46.0.0").
33
*/
4-
export type SDKVersion = '44.0.0' | '45.0.0' | '46.0.0';
4+
export type SDKVersion = '45.0.0' | '46.0.0' | '47.0.0';
55

66
/** @internal */
77
export type SDKSpec = {

packages/snack-sdk/CHANGELOG.md

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,22 @@
44

55
### 🛠 Breaking changes
66

7+
- Dropped Expo SDK 44 ([#360](https://github.com/expo/snack/pull/360) by [@bycedric](https://github.com/byCedric))
8+
79
### 🎉 New features
810

11+
- Upgrade to Expo SDK 47 ([#360](https://github.com/expo/snack/pull/360) by [@bycedric](https://github.com/byCedric))
12+
913
### 🐛 Bug fixes
1014

1115
## 3.9.0 - 2022-08-03
1216

1317
### 🎉 New features
1418

15-
- Upgrade to Expo SDK 46 stable ([#337](https://github.com/expo/snack/pull/337)) by [@bycedric](https://github.com/byCedric))
16-
- Add versioned endpoints for modules ([#334](https://github.com/expo/snack/pull/334)) by [@bycedric](https://github.com/byCedric))
17-
- Upgrade pubnub to 7.2.0 ([#332](https://github.com/expo/snack/pull/332)) by [@bycedric](https://github.com/byCedric))
18-
- Upgrade Snack to Expo SDK 45 ([#290](https://github.com/expo/snack/pull/290)) by [@danstepanov](https://github.com/danstepanov))
19+
- Upgrade to Expo SDK 46 stable ([#337](https://github.com/expo/snack/pull/337) by [@bycedric](https://github.com/byCedric))
20+
- Add versioned endpoints for modules ([#334](https://github.com/expo/snack/pull/334) by [@bycedric](https://github.com/byCedric))
21+
- Upgrade pubnub to 7.2.0 ([#332](https://github.com/expo/snack/pull/332) by [@bycedric](https://github.com/byCedric))
22+
- Upgrade Snack to Expo SDK 45 ([#290](https://github.com/expo/snack/pull/290) by [@danstepanov](https://github.com/danstepanov))
1923

2024
## 3.8.0 - 2022-04-20
2125

@@ -25,16 +29,16 @@
2529

2630
### 🎉 New features
2731

28-
- Prepare snack-sdk and snack-content for SDK 44 ([#277](https://github.com/expo/snack/pull/277)) by [@bycedric](https://github.com/byCedric))
29-
- Split out code related to Snack project definitions into `snack-content` ([#251](https://github.com/expo/snack/pull/251)) by [@ide](https://github.com/ide))
30-
- Upgrade Snack to Expo SDK 44 ([#243](https://github.com/expo/snack/pull/243)) by [@bycedric](https://github.com/byCedric))
32+
- Prepare snack-sdk and snack-content for SDK 44 ([#277](https://github.com/expo/snack/pull/277) by [@bycedric](https://github.com/byCedric))
33+
- Split out code related to Snack project definitions into `snack-content` ([#251](https://github.com/expo/snack/pull/251) by [@ide](https://github.com/ide))
34+
- Upgrade Snack to Expo SDK 44 ([#243](https://github.com/expo/snack/pull/243) by [@bycedric](https://github.com/byCedric))
3135

3236
## 3.7.0 — 2021-12-17
3337

3438
### 🎉 New features
3539

3640
- `SnackState` & `SnackOptions` include `snackId` and `accountSnackId` for tracking snacks, rather than only full name (id).
37-
- `saveAsync` additionally returns `snackId` and `accountSnackId`.
41+
- `saveAsync` additionally returns `snackId` and `accountSnackId`.
3842

3943
## 3.6.0 — 2021-10-29
4044

0 commit comments

Comments
 (0)