Skip to content

PRD-3247: Update to Expo SDK 58 and other dependencies to the latest versions - #59

Draft
VitalyMih wants to merge 6 commits into
mainfrom
chore/PRD-3247-update-dependencies
Draft

VitalyMih wants to merge 6 commits into
mainfrom
chore/PRD-3247-update-dependencies

Conversation

@VitalyMih

Copy link
Copy Markdown
Collaborator

Task: https://app.clickup.com/t/24336023/PRD-3247

This PR updates the workspace and the example app to Expo SDK 58 (React Native 0.88, React 19.3) and the other dependencies to their latest versions, including Nx 24, TypeScript 6 and ESLint 9.39 with @stylistic/eslint-plugin 6. The configs are adapted to the new major versions: Nx 24 migrations, the TypeScript 6 module resolution, renamed @Stylistic rules and the Expo SDK 58 app and Metro config. Unused tooling is removed: the Jest setup, @ronas-it/nx-generators, the eas-build-pre-install script and several packages the workspace no longer imports. The only library code change is in the web WebSocket service, which now converts the Pusher port options to numbers, because @pusher/pusher-websocket-react-native 1.3.6 types them differently from pusher-js. The README gets notes on getFormData with the expo/fetch global fetch and on the R8 rule that Android release builds need for the Pusher native SDK.

Packages (main → PR)

Package main PR
expo ^54.0.0 ~58.0.26
react-native 0.81.4 0.88.1
react, react-dom 19.1.0 19.3.0
expo-constants ~18.0.9 ~58.0.16
expo-image-picker ~17.0.8 ~58.0.10
expo-linking ~8.0.8 ~58.0.17
expo-localization ~17.0.7 ~58.0.5
expo-modules-core ^3.0.21 ~58.1.0
expo-notifications ~0.32.12 ~58.1.9
expo-router ~6.0.12 ~58.0.32
expo-splash-screen ~31.0.10 ~58.0.14
expo-status-bar ~3.0.8 ~58.0.5
expo-updates ~29.0.12 ~58.0.22
expo-system-ui (example app, added by the Nx migration) — ~58.0.7
@expo/metro-runtime ~6.1.2 ~58.0.17
@expo/metro-config → @expo/metro ~54.0.2 ~58.0.0
babel-preset-expo ~54.0.0 ~58.0.26
react-native-safe-area-context ~5.6.0 ~5.11.1
react-native-screens ~4.16.0 ~4.30.1
react-native-svg 15.12.1 15.16.0
react-native-svg-transformer 1.5.1 1.5.3
@pusher/pusher-websocket-react-native (dev and peer) ^1.3.1 ^1.3.6
pusher-js (dev and peer) ^8.4.0 ^8.6.0
reactotron-react-native ^5.1.17 ^5.3.1
@reduxjs/toolkit ^2.9.0 ^2.15.0
i18n-js ~4.5.1 ~4.5.4
lodash-es ^4.17.21 ^4.18.1
nx, @nx/eslint, @nx/eslint-plugin, @nx/expo, @nx/js, @nx/workspace 21.6.4 24.0.6
typescript ~5.9.2 ~6.0.3
eslint, @eslint/js ^9.37.0 ^9.39.5
typescript-eslint, @typescript-eslint/* ^8.46.0 ^8.73.0
@stylistic/eslint-plugin ^5.4.0 ^6.0.1
eslint-plugin-react-hooks ^7.0.0 ^7.1.1
eslint-plugin-unused-imports ^4.2.0 ^4.4.1
globals ^16.4.0 ^17.14.0
prettier ^3.6.2 ^3.10.1
lint-staged ^16.2.7 ^17.6.1
syncpack ^13.0.4 ^15.3.3
@types/react ~19.1.10 ~19.3.0
@types/node (CI runs on Node 22) 24.7.2 22.20.5

Removed as unused: @ronas-it/nx-generators, @nx/jest, @eslint/compat, @expo/cli (comes with expo), eslint-plugin-jsx-a11y, @react-native-community/cli-server-api, @react-native/js-polyfills, metro, metro-config, metro-react-native-babel-transformer.

The library's own peer dependencies keep *. reactotron-core-client is now declared as an optional peer: the Reactotron plugin types import it, and before it only came in transitively.

Code changes

  • src/lib/src/data-access/websocket/service.web.ts: wsPort/wssPort from the shared handlers are converted to number before they are passed to pusher-js. Pusher RN 1.3.6 types them as Number, so the web service no longer type-checked.
  • apps/example/app.config.ts: config types come from expo/config, the splash screen moves to the expo-splash-screen plugin, newArchEnabled is removed (the New Architecture is the only one now).
  • apps/example/metro.config.js: getDefaultConfig from expo/metro-config, mergeConfig from @expo/metro/metro-config.
  • apps/example/package.json: Expo SDK 58 versions. EAS update scripts pass --environment explicitly.
  • tsconfig.base.json, apps/example/tsconfig.json, types.d.ts: TypeScript 6 deprecates baseUrl and the node module resolution. The configs switch to bundler resolution with relative paths and keep the TypeScript 5 defaults for types and side-effect imports. The svg typings are imported by package name.
  • .eslint.ronasit.cjs, eslint.base.cjs, eslint.config.cjs: rules renamed or removed for @Stylistic 6 (func-call-spacing → function-call-spacing, jsx-props-no-multi-spaces and jsx-indent removed). The ignore entry for the removed nx-generators file is dropped, and so is the unused legacy src/lib/.eslintrc.json.
  • Nx 24 migrations: affected.legacy in nx.json, new .nx/.claude entries in .gitignore/.prettierignore, a single wildcard rule in eslint.constraints.json. The obsolete tools/scripts/eas-build-pre-install.mjs is removed.
  • Jest configs (jest.config.ts, jest.preset.js, apps/example/jest.config.ts, apps/example/tsconfig.spec.json) are removed: the repository has no tests.
  • package.json: deps:sync uses the syncpack 15 command syncpack fix. .npmrc: min-release-age=3.
  • README.md: notes on getFormData with expo/fetch and on the Android R8 rule.

Verification

  • All six modules (safe-area-view, i18n, image-picker, push-notifications, websocket, reactotron) were checked by hand on the example app: iOS simulator (iOS 26.5), Android emulator (API 35) and web (Chrome). The checks used temporary verification screens that are not part of this PR. On web, push notifications are a stub, as before.
  • Android release: with code shrinking enabled (the default in the SDK 58 template), R8 fails with Missing class org.slf4j.impl.StaticLoggerBinder, which comes from the Pusher native SDK. With -dontwarn org.slf4j.impl.StaticLoggerBinder the build passes, and websocket (public channel) and push work. This is documented in the README.
  • npm run lint and tsc (root, library, example app) pass. expo export passes for iOS and Android. For web, expo export needs react-native-web, which the example app does not depend on (same as main), so web was checked with it added temporarily.
  • npm audit (2026-12-04): 32 vulnerabilities: 1 low, 29 moderate, 1 high, 1 critical (main: 96, including 61 high and 6 critical). The high one is ws 8.21.3 (via @expo/cli). The critical one is cross-spawn 7.0.6 (Windows only; via eslint, cross-env, Expo CLI). Both are in CLI and dev tooling, and both come from advisories that were not reported yet when the update was verified (0 high and 0 critical then). main has vulnerable versions of both packages as well. They are not fixed in this PR.

Known issues / not in this PR

  • getFormData with the global fetch: since Expo SDK 56 the global fetch on iOS and Android is expo/fetch, which rejects the { uri, name, type } file parts with Unsupported FormDataPart implementation. XMLHttpRequest (e.g. axios) still works. A fix is in progress, which is why this PR is a draft.
  • getFormData on web sends [object Object] instead of the file, the same as on main.
  • Android websocket: after a failed private channel authorization, the native Pusher client stops delivering events (public channels included) until the app restarts. main (Expo 54, Pusher RN 1.3.1) behaves the same way. Upstream: onAuthorizer runs sequentially on Android pusher/pusher-websocket-react-native#37
  • Release 2.1.0 follows after the merge.

vmikhalevskii added 6 commits December 4, 2026 13:41
Apply the Nx 24 migrations: legacy affected mode in nx.json, new
.nx and .claude entries in .gitignore and .prettierignore, a single
wildcard module-boundaries constraint instead of the generator
defaults. Remove the obsolete eas-build-pre-install script that
patched @nx/expo for EAS Build.

The repository has no tests, so remove the Jest configs, the example
tsconfig.spec.json and its reference together with the @nx/jest
dependency.

Refs: https://app.clickup.com/t/123kjkdqy91
TypeScript 6 deprecates baseUrl and the node module resolution, so
switch to the bundler resolution with relative paths, keep side-effect
imports unchecked and load all available types. types.d.ts now imports
the svg typings by package name.

Rename the @Stylistic rules for @stylistic/eslint-plugin 6
(func-call-spacing -> function-call-spacing, drop the removed
jsx-props-no-multi-spaces and jsx-indent), drop the ignore of the
removed nx-generators file and the unused legacy lib .eslintrc.json.

Refs: https://app.clickup.com/t/123kjkdqy91
Update the example app dependencies to Expo SDK 58 and React Native
0.88 (expo install versions, expo-system-ui added). Move the splash
screen settings to the expo-splash-screen plugin, drop
newArchEnabled (the New Architecture is the only one now), take the
config types from expo/config and use the metro config from
expo/metro-config and @expo/metro. EAS update scripts now pass the
environment explicitly.

Refs: https://app.clickup.com/t/123kjkdqy91
Update the workspace to Expo SDK 58, React Native 0.88, React 19.3,
Nx 24, TypeScript 6, ESLint 9.39 with @stylistic/eslint-plugin 6,
@pusher/pusher-websocket-react-native 1.3.6 and pusher-js 8.6.

Remove the dependencies the workspace no longer uses
(@ronas-it/nx-generators, @nx/jest, @eslint/compat, @expo/cli,
eslint-plugin-jsx-a11y, metro packages replaced by @expo/metro and
others), switch deps:sync to the syncpack 15 command, add
reactotron-core-client as an optional peer dependency of the library
and wait 3 days before installing freshly published versions
(min-release-age).

Refs: https://app.clickup.com/t/123kjkdqy91
@pusher/pusher-websocket-react-native 1.3.6 types wsPort and wssPort
as the Number wrapper, while pusher-js expects number, so passing the
shared handlers to pusher-js no longer type-checks. Convert both ports
to number before passing them to pusher-js on web.

Refs: https://app.clickup.com/t/123kjkdqy91
Since Expo SDK 56 the global fetch on iOS and Android is expo/fetch,
which may not accept the file parts created by getFormData; describe
the workarounds. Document the R8 rule an Android release build with
code shrinking needs for the slf4j class referenced by
@pusher/pusher-websocket-react-native.

Refs: https://app.clickup.com/t/123kjkdqy91
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.

2 participants