3 ms·
I've found the trickiest parts of cross-platform app development is that some features on a platform just have no analogue on other platforms. For example, not
by nostrademons 11y ago
I've found the trickiest parts of cross-platform app development is that some features on a platform just have no analogue on other platforms. For example, notifications on Android can have BigViews in either text, list, or inbox styles. They're also supposed to collapse, although some apps (I'm looking at you, Facebook) don't bother. The equivalent on iOS is just badging the icon and showing a short 1-line text string as an alert. That means that some information which would've gone straight into the notification on Android needs to be shown on app launch in iOS, which often completely changes the data structures you'd use to represent it. Oftentimes this can ripple through the app as well, where because you need to launch the app to see it on iOS, you might as well add extra interactivity to this data, but that's not allowed by the Android platform as long as you want to keep it in a notification.
This doesn't matter if all your cross-platform C++ or Xamarin library does is format strings, provide predicates, and clean data - which is probably what it should do. But it means that the dream of a business logic layer that just hands off objects to the UI to render is just a dream. You need to hand off wildly different objects for a short notification on Android vs. an inbox-style notification vs. an iOS notification vs. an Intent to start an Activity on Android vs. an options dictionary for application:didFinishLaunchingWithOptions:.