Skip to content
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

Changes in React Native 0.77 and Above: Migration from Objective-C to Swift in AppDelegate #2802

Open
kasumil opened this issue Feb 21, 2025 · 10 comments

Comments

@kasumil
Copy link

kasumil commented Feb 21, 2025

Since React Native version 0.77, the AppDelegate has been changed from Objective-C to Swift for iOS projects. This means that your import statements and setup might need to be adjusted accordingly.

Can you tell me when these changes will be applied?

@jieey1140
Copy link

+1

1 similar comment
@seckinbrke
Copy link

+1

@seckinbrke
Copy link

Its urgent I think. Because we can not setup for new version of react-native.

@Minishlink
Copy link

Minishlink commented Feb 23, 2025

Hello, you can use @appzung/react-native-code-push module. It is compatible with these changes and will be maintained in the long term with other RN changes (and also new features when paying for AppZung).

When using this module, if you still target AppCenter you can simply point your CodePushServerUrl to https://codepush.appcenter.ms/ in your Info.plist/strings.xml. After AppCenter shutdown, you can then remove the CodePushServerUrl to use AppZung, or point to an instance of Microsoft's open source CodePush server (which is not production-ready).

If you have any positive or negative feedback about AppZung please reach out [email protected]!

@IlyaBausovAkvelon
Copy link

@kasumil,
Due to App Center deprecation we are not planning to implement this change.

@StockFish233
Copy link

I use CodePush.bundleURL; Instead of Bundle.main.url(forResource: "main", withExtension: "jsbundle"), codepush seems to be working.

Image

@FernandoAOborges
Copy link

Eu uso CodePush.bundleURL;Em vez de Bundle.main.url(forResource: "main", withExtension: "jsbundle"), o codepush parece estar funcionando.

Image

Is the fix working with this change in React Native version 0.77 or 0.78? I'd be happy to help you check the compatibility. Could you please provide more details about the specific fix or issue you're referring to? This will help me give you a more accurate answer.

@StockFish233
Copy link

StockFish233 commented Feb 27, 2025

透過使用CodePush.bundleURL;Em vez de Bundle.main.url(forResource: "main", withExtension: "jsbundle"),codepush 可以正常運作。
Image

此修復是否適用於 React Native 版本 0.77 或 0.78 中的此變更?我很樂意幫助您檢查相容性。您能否提供有關您所指的具體修復或問題的更多詳細資訊?這將有助於我給你更準確的答案。

Yes, I am using react-native 0.78, AppDelegate changed from Objective-C to Swift, docs/setup-ios.md provided is Objective-C writing, so I tried to change, but I don't understand Swift at all. If anyone can help me, thank you very much!

@kasumil
Copy link
Author

kasumil commented Feb 27, 2025

I believe that CodePush will no longer be updated, so I have replaced it with the hot-updater library.

@Minishlink
Copy link

@StockFish233 CodePush will be updated at this repo, we commit to keep compat with CodePush classic servers. Very easy to setup : https://github.com/AppZung/react-native-code-push/blob/main/docs/advanced-usage.md#using-a-custom-server-url

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

No branches or pull requests

7 participants