News for hackers. Stuff that matters.
Re:Ask HN: How many of you Apple developers still use Object... by troupo on Tuesday February 20, 2024 @11:55AM (#39443635)
> There probably isn't any reason to start a new app or library with anything other than Swift.

Unless you do anything for MacOS and care about MacOS. Most Swift UI apps I've seen feel foreign on MacOS in innumerable ways.

Re:Ask HN: How many of you Apple developers still use Object... by ironlake on Tuesday February 20, 2024 @12:11PM (#39443842)
Thanks for that perspective. I haven't done any MacOS development.
Re:Ask HN: How many of you Apple developers still use Object... by troupo on Tuesday February 20, 2024 @12:25PM (#39444033)
Since Swift UI is iOS-first, when the apps get ported to MacOS, they bring a lot of mobile-isms: the views and animations are often wrong, the controls are often wrong (like even the Apple's own settings app breaks a lot of established platform conventions and Apple's own HIGs), integration with system services is often incomplete (like proper keyboard shortcuts, I can't set a shortcut for Conversations->Delete in Messages anymore) etc.

Because of that I've seen people discuss that they have to reach for AppKit and/or ditch SwiftUI and got all in with AppKit, and that is easier to do from Obj-C.

Re:Ask HN: How many of you Apple developers still use Object... by Reason077 on Wednesday February 21, 2024 @12:38AM (#39450504)
> "people discuss that they have to reach for AppKit and/or ditch SwiftUI and got all in with AppKit, and that is easier to do from Obj-C."

You can fairly easily port UIKit apps to macOS now with Mac Catalyst[1] No need to use SwiftUI to get those mobile-isms.

[1] https://developer.apple.com/mac-catalyst/

Re:Ask HN: How many of you Apple developers still use Object... by markemer on Wednesday February 21, 2024 @12:47AM (#39450565)
Also AppKit works perfectly well in swift. People just probably remember the ObjC versions of things better since that’s where this all started. But the naming is pretty standard if you remember the old calls.
Re:Ask HN: How many of you Apple developers still use Object... by troupo on Wednesday February 21, 2024 @03:14AM (#39451300)
Catalyst is just as bad IMO
Re:Ask HN: How many of you Apple developers still use Object... by sumuyuda on Tuesday February 20, 2024 @12:51PM (#39444361)
You can use AppKit in Swift just like you can use UIKit on iOS. There is no requirement to use SwiftUI when creating a macOS swift app.
Re:Ask HN: How many of you Apple developers still use Object... by markemer on Wednesday February 21, 2024 @12:45AM (#39450556)
Yeah the wrapper is the same, it’s just NSView instead of UIView and the like. But the API is wrapped just as well.