feat: migrate template to Swift#45
Conversation
cipolleschi
left a comment
There was a problem hiding this comment.
Love this, but as I mention in chat, 0.76 will already have a lot of changes for the users. I'd like to be a little more conservative and wait for 0.77 before pushing the template in Swift to them.
WDYT?
Also... have we tried building an app with the template using
- static framewors
- dynamic frameworks
They must work without chages required before we can push these changes.
|
@cipolleschi It's your call if you think we can't squeeze Swift template into 0.76 then Im fine with 0.77 👍🏻 I want to start the discussion around this and polish all the edges that might still be missing. I will test out building with static and dynamic frameworks! |
|
@cipolleschi I've just checked and it looks like both: and Are building properly! |
Summary: This PR exposes the `newArchEnabled` flag and deprecates all of the separate methods to enable new architecture. As discussed with cipolleschi here: react-native-community/template#45 (comment) ## Changelog: [IOS] [DEPRECATED] - Deprecate turboModuleEnabled, fabricEnabled, bridgelessEnabled [IOS] [ADDED] - Add newArchEnabled method to RCTAppDelegate Pull Request resolved: #46228 Test Plan: Test if switching newArchEnabled flag from AppDelegate works. Reviewed By: cortinico Differential Revision: D61849385 Pulled By: cipolleschi fbshipit-source-id: 8acf718386882679f00d2d5000b4432a523b34ac
|
Hey @cipolleschi Is there anything else we need to get this one merged? The |
|
I think we can merge it! :D |
Summary:
This PR removes Objective-C from the template.
Now that the template is decoupled from the core repository we can shift from Objective-C to Swift.
The
React_RCTAppDelegateis fully compatible to work with Swift:One thing to figure out is the upgrade helper, but we had a similar situation while migrating from java to kotlin:
Note: We've been shipping Swift for React Native visionOS for last 3 major releases, so has been tested already.
Changelog:
[IOS] [ADDED] - Migrate from Objective-C to Swift
Test Plan:
Generate project using Swift template.