|
|
|
|
|
by alin23
1574 days ago
|
|
I think they serve different purposes.
Catalyst is mostly used when you’ve already written your iPad app (either in UIKit or iOS specific SwiftUI) and now you want to make that app available on Mac without rewriting parts of the code. You can indeed write a multiplatform app in SwiftUI nowadays. That’s what I’m doing with Volum (https://lowtechguys.com/volum) which easily shares 95% of the code between macOS, iOS and iPadOS, and only platform specific code like keyboard shortcuts or volume OSD is isolated. But you kinda have to start with that multiplatform mindset from the start, otherwise you’ll soon find out you used too many custom NSViews and Cocoa APIs, your UI is not designed for portrait mode, and it’s a burden to place #if os(macOS) guards all over the place now. |
|