-
Notifications
You must be signed in to change notification settings - Fork 5
Upgrade to new architecture #13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Excellent work! Did you look at the Expo Modules API? Apparently it has better DX unless you're doing low level C++ stuff, so probably Turbo Modules is a better choice 👍 |
- Add event emitter support for TurboModules (addListener/removeListeners) - Fix iOS getSampleRate method signature for old arch bridge compatibility - Fix Android getSampleRate method signature (remove extra parameter) - Create old arch package (ElementaryTurboPackage) for Android bridge mode - Remove pre-generated codegen folders - now generated at consumer build time - Update iOS header to import spec from Pods headers - Consolidate iOS example to single project with arch toggle - Update Podfile with clear architecture toggle comment - Update C++ standard to c++20 for React Native 0.78 compatibility - Fix ESLint config to use correct package name (@react-native) Both architectures tested and working on iOS and Android. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add missing ESLint dependencies (eslint-plugin-ft-flow, hermes-eslint) - Add metro-react-native-babel-preset for Jest - Fix Jest modulePathIgnorePatterns to exclude example_old - Remove codegen from bob targets (runs at consumer build time) - Update Java version from 11 to 17 for React Native 0.78 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
@tamlyn sorry I could only come back to this now but I revisited the PR with the help of Claude Code and completed the migration, tested for old and new architecture and it all works. |
- Add example-expo/ with Expo SDK 53 and React Native 0.79 - Configure expo-dev-client for development builds - Add metro.config.js with resolveRequest to fix React duplicates in monorepo - Add react-native.config.js for proper codegen integration - Update root package.json with example-expo script - Update .gitignore for Expo generated folders Note: This library requires a development build (`expo run:ios/android`) and cannot run in Expo Go due to native C++ Elementary Audio dependency. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
Bonus: added expo example as well |
- Add example-expo/ to eslintIgnore - Add example-expo and example_old to tsconfig.build.json exclude 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The types paths incorrectly included /src/ which doesn't exist in the build output. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
tamlyn
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not going to pretend I understand it, but it builds and it makes a beep so 👍
Why
The new architecture has been out for a while and has many benefits that will help the goals of this project. With this in mind I decided to upgrade the codebase to support the new architecture - linked issue #12
How
The upgrade process of RN projects on the native side is always painful and messy. I am sure there is things I could have done better if I had an idea exactly where to go. The process involved reading the docs for []builder-bob](https://callstack.github.io/react-native-builder-bob/faq#how-does-the-library-get-linked-to-the-example-app-in-the-generated-project), new architecture native modules, using a bit of cursor and claude (which to be honest didn't help much).
Here is what I did:
Elementary.mmto support new architecture apiexample_oldI would like to also test this all works in an expo project as expo is now the default react-native framework.
To-do