Skip to content

Conversation

@brainbicycle
Copy link

Fixes args not being populated on iOS side on new architecture.

the getConstants() defined in the typescript spec is reserved keyword on modules so we have to use the new arch method signatures in order to get the callbacks.

Follow-ups

  • This is likely not compatible with old architecture, if we want that will need to add back the old style constantsToExport method and update the exported types in index.ts

Updates the implementation to correctly use TurboModule APIs:
- iOS: Implement getConstants/constantsToExport with typed ModuleConstants return type
- JS: Use TurboModule spec instead of legacy NativeModules API

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
@brainbicycle brainbicycle self-assigned this Dec 18, 2025
@MounirDhahri
Copy link
Member

Thank you @brainbicycle

Support both old and new React Native architectures by using preprocessor directives in iOS native code and falling back to NativeModules when TurboModules are unavailable in JavaScript.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
@MounirDhahri
Copy link
Member

@brainbicycle can we merge this 👀

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.

3 participants