-
Notifications
You must be signed in to change notification settings - Fork 0
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
[BIG-PR] Refactor Android-Specific Code to Kotlin Multiplatform Support #70
Conversation
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.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
ktlint
🚫 [ktlint] standard:function-start-of-body-spacing reported by reviewdog 🐶
Expected a single white space before start of function body
komoju-mobile-sdk/shared/src/iosMain/kotlin/com/komoju/mobile/sdk/MainViewController.kt
Line 35 in 4c49bd7
override fun viewWillDisappear(animated: Boolean){ |
🚫 [ktlint] standard:function-signature reported by reviewdog 🐶
Expected a single space before body block
komoju-mobile-sdk/shared/src/iosMain/kotlin/com/komoju/mobile/sdk/MainViewController.kt
Line 35 in 4c49bd7
override fun viewWillDisappear(animated: Boolean){ |
🚫 [ktlint] standard:no-blank-line-before-rbrace reported by reviewdog 🐶
Unexpected blank line(s) before "}"
komoju-mobile-sdk/shared/src/iosMain/kotlin/com/komoju/mobile/sdk/MainViewController.kt
Line 49 in 4c49bd7
🚫 [ktlint] standard:no-consecutive-blank-lines reported by reviewdog 🐶
Needless blank line(s)
Used code based resources as of now.
…ltiplatform Support (#70) * Moved the SDK UI to the shared module * ktlint fixup * Use default Res Package directory * Got rid of resources as iOS have issues with them. Used code based resources as of now. * Added Japanese i18n * Dynamic height fraction * ktlint fixup * added more strings * improved docs * enum naming changes * ktlint fixup
Overview:
In this PR, I have refactored the project to move both the UI components and network-related code from the Android-specific implementation to the
shared
module. Previously, the shared module was only used for non-UI code, such as network API calls and business logic, while the UI was Android-specific. With this change, both the UI and network code are now part of the shared module, allowing us to leverage Kotlin Multiplatform and Compose for both Android and iOS. This shift will enable us to reuse the UI components across both platforms and improve the maintainability and consistency of the codebase.Changes Made:
Moved UI Code to Shared Module:
expect/actual
where needed.Network Code in Shared Module:
Platform-Specific Implementations:
expect/actual
mechanisms to manage platform-specific differences, such as different handling of navigation or platform-specific APIs. This ensures that the shared module can accommodate platform-specific requirements without duplicating logic.Compose Multiplatform Support:
Dependencies Updated:
iOS Support:
Key Benefits:
Next Steps:
Notes: