I started a sample iOS app in order to explore SwiftUI; at some point I thought enabling Mac support would be a fun thing try, and surprisingly, I have good result with little to no additional code.
Testing the app on the Mac, I notice the app quits once I close its window, which is not the way most apps work.
Trying to use applicationShouldHandleReopen is not an option since NSApplicationDelegate is not possible for Catalyst, I was not able to find a counterpart either in UIApplicationDelegate or UISceneDelegate, and I was not able to find anything on this topic on Apple's documentation.
What's the proper way to implement the traditional Mac app behavior(†) on a Catalyst app?
(†) Traditional mac app behavior: When the app window is closed, the app icon remains in the doc and if you click it the apps window reappears again
Original answer
To summarize, do one of the followings
Info.plistAnother answer in the same question recommends setting
NSSupportsAutomaticTerminationtoNO. This also works, but I am not sure if messing withNSSupportsAutomaticTerminationbrings you "surprises".