Skip to content

Expo SDK 57: runs in today's Expo Go, Clerk Core 3, no request loop - #3

Merged
FilipKalcic1 merged 3 commits into
mainfrom
sdk-57
Sep 30, 2026
Merged

FilipKalcic1 merged 3 commits into
mainfrom
sdk-57

Conversation

@FilipKalcic1

Copy link
Copy Markdown
Owner

Summary

  • Expo SDK 57: React Native 0.86 (New Architecture), React 19, Expo Router 57, Reanimated 4, bottom-sheet 5, Stripe 0.64, so the app opens in the current Expo Go.
  • Replaced two libraries that crash on RN 0.86: react-native-swiper became a FlatList pager, and react-native-modal became AppModal on React Native's own Modal.
  • Missing keys no longer crash the app: a "Setup needed" screen lists the missing EXPO_PUBLIC_* keys and, through the new public GET /(api)/health, the missing server settings (names only). Payment without a Stripe key shows a disabled button, and without a Places key the From and To fields offer seven popular Zagreb places.
  • Expo Go reaches the API under npx expo start without EXPO_PUBLIC_API_ORIGIN. Release builds stay fail-closed.
  • Clerk Core 3 (@clerk/expo 4.7.2) replaces the deprecated @clerk/clerk-expo, so the deprecation toast is gone. Two reviews ran the real clerk-js 5.128 and 6.35 builds and found 7 behaviour changes. Each is fixed with tests that failed first:
    • "Can't connect" + Retry instead of a blank screen when Clerk is unreachable at launch;
    • offline sign-out still cleans up;
    • the token wait is bounded by the 10 s load timeout;
    • session activation is retried;
    • network errors read as plain text.
  • Request loop fixed: useFetch kept useAuth().getToken, which is a new function on every render, in its dependencies. Once a user signed in, the drivers and the ride history were refetched after every answer. The focus refetch works again as a result.
  • Tooling: expo lint ., TypeScript 6, RNTL 13, Node 24 in CI (.nvmrc), and a new iOS bundle export step in CI.
  • Docs: the README has a "Run it on your iPhone" section; plan r7–r7.2 adds rows EG1–EG9 and W11.

Test plan

  • npm run check: tsc, lint, 74 suites / 2,929 tests, coverage 100% lines / 99.66% branches
  • npm run mutants: R01–R11 all killed
  • npx expo export -p ios, -p android, -p web
  • npx expo-doctor 21/21 · npx expo install --check
  • Dev server with an empty .env.local serves the SDK 57 manifest and bundle; /(api)/health names the four missing settings
  • CI on GitHub (first run with Node 24 and the iOS export)
  • On-device QA in Expo Go (BUILD_PLAN §12 steps 0, 3b, 17, 18)

🤖 Generated with Claude Code

FilipKalcic1 and others added 3 commits September 29, 2026 22:21
- Expo SDK 57, React Native 0.86 (New Architecture), React 19.2, Expo Router 57,
  Reanimated 4 + worklets, bottom-sheet 5, Clerk 2.20 (useSSO), Stripe 0.64
- Replace react-native-swiper (ViewPropTypes) with a FlatList pager and
  react-native-modal (BackHandler.removeEventListener) with AppModal on RN's
  Modal: both crashed on RN 0.86
- Missing keys no longer crash: a "Setup needed" screen lists the missing
  EXPO_PUBLIC_* keys and, via the new public GET /(api)/health, the missing
  server settings (names only) (EG1-EG3)
- Under `npx expo start` an empty EXPO_PUBLIC_API_ORIGIN uses the dev server,
  so Expo Go reaches the API routes; release builds stay fail-closed (EG4)
- Payment without a Stripe key shows a disabled button instead of crashing;
  the Payment Sheet return URL comes from Linking.createURL (EG5, EG6)
- One GestureHandlerRootView at the root; bottom-sheet 5 dynamic sizing off
- Without a Places key, From/To offer seven popular Zagreb places (W11)
- expo-router 57: dismissTo where navigate would now push a duplicate
- Notification triggers typed (DATE); notification handler uses banner/list
- Tooling: `expo lint .`, TypeScript 6 types, RNTL 13, Node 24 in CI
- README "Run it on your iPhone" section, plan r7, re-rendered README images

npm run check: 73/73 suites, 2872/2872 tests; iOS/Android/web exports pass;
expo-doctor 21/21; npm run mutants: R01-R11 killed.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…loop

- @clerk/clerk-expo 2.20 (deprecated; its import logged a yellow toast on
  every Expo Go launch) -> @clerk/expo 4.7.2; sign-in and sign-up keep the
  Core 2 API through @clerk/expo/legacy; a lint rule bans the old package
  in imports, require(), jest.mock() and import() (EG8)
- Two independent reviews ran the real clerk-js 5.128 and 6.35 builds and
  found 7 behaviour changes, each fixed with tests that failed first:
  - Clerk unreachable at launch: "Can't connect" + Retry, not a blank screen
  - offline sign-out still resets the trip, cancels reminders, navigates
  - the session-token wait counts towards the 10 s load timeout (was ~2.7 min)
  - a completed sign-in/sign-up/Google sign-in whose activation fails is
    retried, and sign-up never asks for the spent code again
  - network failures read as one plain line, not Clerk's endpoint URL
  - react and react-dom pinned to one version (@clerk/react 6 loads ReactDOM)
- useFetch: @clerk/expo's useAuth returns a new getToken on every render,
  which re-created fetchData after every answer: a request loop for the
  drivers and the ride history once signed in. getToken now lives in a ref;
  refetch keeps its identity, so the focus refetch (H6) works again (EG9)
- Tabs imported from expo-router/js-tabs (the old import is deprecated)
- Plan r7.1/r7.2: EG8, EG9, R31, §9 CI text (the r6.2 workflow ran green)

npm run check: 74/74 suites, 2929/2929 tests, coverage 100 / 99.66;
iOS/Android/web exports pass; expo-doctor 21/21; mutants R01-R11 killed.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@FilipKalcic1
FilipKalcic1 merged commit 01e2414 into main Sep 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant