Skip to content

Commit be606f9

Browse files
authored
chore: upgrade expo to SDK 56 and fix oauth (#280)
1 parent 6da9f1b commit be606f9

7 files changed

Lines changed: 2628 additions & 1641 deletions

File tree

apps/expo-example/app.json

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,6 @@
66
"orientation": "portrait",
77
"icon": "./assets/icon.png",
88
"userInterfaceStyle": "light",
9-
"splash": {
10-
"image": "./assets/splash-icon.png",
11-
"resizeMode": "contain",
12-
"backgroundColor": "#ffffff"
13-
},
149
"scheme": "zerodev-example",
1510
"experiments": {
1611
"typedRoutes": true
@@ -57,6 +52,10 @@
5752
],
5853
"category": ["BROWSABLE", "DEFAULT"]
5954
}
55+
],
56+
"permissions": [
57+
"android.permission.USE_BIOMETRIC",
58+
"android.permission.USE_FINGERPRINT"
6059
]
6160
},
6261
"web": {
@@ -71,6 +70,14 @@
7170
{
7271
"faceIDPermission": "Authenticate to reveal your wallet seed phrase or private key."
7372
}
73+
],
74+
[
75+
"expo-splash-screen",
76+
{
77+
"image": "./assets/splash-icon.png",
78+
"resizeMode": "contain",
79+
"backgroundColor": "#ffffff"
80+
}
7481
]
7582
]
7683
}

apps/expo-example/assetlinks/public/.well-known/apple-app-site-association

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
{
55
"appIDs": ["88J4C462WP.com.zerodev.expoexample"],
66
"components": [
7-
{ "/": "/verify-email*" }
7+
{ "/": "/verify-email*" },
8+
{ "/": "/oauth-callback*" }
89
]
910
}
1011
]

apps/expo-example/package.json

Lines changed: 26 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -12,42 +12,45 @@
1212
},
1313
"dependencies": {
1414
"@react-native-async-storage/async-storage": "2.2.0",
15+
"@expo/dom-webview": "56.0.1",
16+
"@expo/metro-runtime": "~56.0.0",
1517
"@tanstack/react-query": "^5.90.21",
1618
"@turnkey/api-key-stamper": "0.6.4",
1719
"@turnkey/crypto": "2.8.13",
18-
"@turnkey/react-native-passkey-stamper": "1.2.12",
20+
"@turnkey/react-native-passkey-stamper": "1.2.16",
1921
"@wagmi/core": "^2.22.0",
2022
"@zerodev/wallet-core": "workspace:^",
2123
"@zerodev/wallet-react": "workspace:^",
22-
"babel-preset-expo": "^55.0.13",
23-
"expo": "~55.0.9",
24-
"expo-clipboard": "^55.0.9",
25-
"expo-constants": "~55.0.15",
26-
"expo-dev-client": "~55.0.28",
27-
"expo-linking": "^55.0.14",
28-
"expo-local-authentication": "~55.0.13",
29-
"expo-router": "~55.0.13",
30-
"expo-screen-capture": "~55.0.13",
31-
"expo-secure-store": "^55.0.9",
32-
"expo-splash-screen": "~55.0.19",
33-
"expo-status-bar": "~55.0.5",
34-
"expo-web-browser": "^55.0.10",
35-
"react": "19.2.0",
36-
"react-dom": "19.2.0",
37-
"react-native": "0.83.4",
38-
"react-native-get-random-values": "^2.0.0",
39-
"react-native-passkey": "^3.3.2",
40-
"react-native-safe-area-context": "~5.6.2",
41-
"react-native-screens": "~4.23.0",
24+
"babel-preset-expo": "~56.0.0",
25+
"expo": "~56.0.0",
26+
"expo-clipboard": "~56.0.0",
27+
"expo-constants": "~56.0.0",
28+
"expo-dev-client": "~56.0.0",
29+
"expo-linking": "~56.0.0",
30+
"expo-local-authentication": "~56.0.0",
31+
"expo-router": "~56.2.0",
32+
"expo-screen-capture": "~56.0.0",
33+
"expo-secure-store": "~56.0.0",
34+
"expo-splash-screen": "~56.0.0",
35+
"expo-status-bar": "~56.0.0",
36+
"expo-system-ui": "~56.0.0",
37+
"expo-web-browser": "~56.0.0",
38+
"react": "19.2.3",
39+
"react-dom": "19.2.3",
40+
"react-native": "0.85.3",
41+
"react-native-get-random-values": "~1.11.0",
42+
"react-native-passkey": "^3.5.0",
43+
"react-native-safe-area-context": "~5.7.0",
44+
"react-native-screens": "4.25.2",
4245
"react-native-web": "^0.21.2",
43-
"react-native-webview": "13.16.0",
46+
"react-native-webview": "13.16.1",
4447
"tslib": "^2.8.1",
4548
"uuid": "^13.0.0",
4649
"viem": "~2.38.6",
4750
"wagmi": "^2.19.0"
4851
},
4952
"devDependencies": {
50-
"@types/react": "~19.2.2",
53+
"@types/react": "~19.2.14",
5154
"typescript": "~5.9.2"
5255
},
5356
"private": true

apps/expo-example/src/components/export/ExportBox.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ const styles = StyleSheet.create({
7171
overflow: 'hidden',
7272
},
7373
statusOverlay: {
74-
...StyleSheet.absoluteFillObject,
74+
...StyleSheet.absoluteFill,
7575
flexDirection: 'row',
7676
alignItems: 'center',
7777
justifyContent: 'center',

packages/react/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@
121121
"devDependencies": {
122122
"@types/react": "^19",
123123
"expo-linking": "^8.0.8",
124-
"expo-web-browser": "^15.0.7",
124+
"expo-web-browser": ">=15.0.7 <57",
125125
"react-native": "0.83.4",
126126
"react-native-webview": "13.16.0",
127127
"typescript": "5.9.3",

packages/react/src/native/oauth/expoWebBrowser.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,17 @@ export function createOAuthGetSessionIdWithExpoWebBrowser(params: {
4646
// The other path: the auth browser session observes the redirect to
4747
// redirectUri itself and resolves with the URL. Fires on iOS always,
4848
// and on Android whenever no verified app-link intent steals it first.
49+
//
50+
// `preferUniversalLinks: true` is required on iOS 17.4+ to make
51+
// ASWebAuthenticationSession intercept HTTPS callbacks via the app's
52+
// Associated Domains AASA. Without it, iOS falls back to the legacy
53+
// `callbackURLScheme:` API with "https" as the scheme, which intercepts
54+
// nothing — the browser sheet stays open and the callback URL loads
55+
// as a normal web page. No-op on Android.
4956
const fromBrowser = WebBrowser.openAuthSessionAsync(
5057
oauthUrl,
5158
params.redirectUri,
59+
{ preferUniversalLinks: params.redirectUri.startsWith('https:') },
5260
).then((r) => {
5361
if (r.type !== 'success') throw new Error('OAuth cancelled or failed')
5462
const parsed = new URL(r.url)

0 commit comments

Comments
 (0)