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

[iOS] Add workaround for using Moko in tests and previews #114

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

JuliaJakubcova
Copy link
Contributor

📝 Description

  • Add workaround for using Moko in tests and previews

💡 What’s new?

  • Workaround, one class in kotlin in iOS Main and two methods in UIToolkit in Swift

😶 What’s missing?

  • Haven't tested with previews, only with tests

📚 References

pchmelar
pchmelar previously approved these changes Sep 26, 2024
Copy link
Member

@pchmelar pchmelar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

Copy link
Contributor

@tomas-bat tomas-bat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried to test iOS previews and I was getting some error related to our UIToolkit Bundle+Extensions.swift file..

It was probably some workaround which now causes crashes, but when I tried to use .module instead of this workaround, the previews started working 😅 So maybe the workaround is outdated or something..

This isn't really related to this PR, though.. So let me know if you want to look into it and fix it here, or if I should create a task for it..

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we still need this? 🤔 It seems to be created in the stencil files.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried my best to remove the hack from swiftgen files, but this is the best I can do 😅 I think an iOS developer will know more about how they work and will be able to remove a lot of code and then this will not be needed anymore, but that's beyond my skills

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Understandable 😅 I checked it and this file can be safely removed. But you don't have to do it here, I think.. We'll do that in MateeStarter.

@tomas-bat
Copy link
Contributor

Don't know why Github decided to close this 😅

@tomas-bat tomas-bat reopened this Oct 24, 2024
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