4 ms·
The documentation of SwiftUI is poor but I was able to create mostly what I wanted from it, this was a year or so ago. I released a SwiftUI calculator I built
by math-dev 5y ago
The documentation of SwiftUI is poor but I was able to create mostly what I wanted from it, this was a year or so ago.
I released a SwiftUI calculator I built earlier as open source on GitHub, it may be useful for some dipping their toes into it.
I actually really enjoyed working in SwiftUI. Towards the end of my time, I started moving into a hybrid approach where I would borrow some of the concepts of CSS stylesheets and clearly separate constant parameters used in UX into their own swift files (making it easier to flip between them, eg when going from light mode to dark or from iPhone to iPad)
Link: https://github.com/ashok-khanna/RPN-31 https://github.com/ashok-khanna/RPN-31
- read_if_gay_ 5y ago> I was able to create mostly what I wanted from it Is "what I wanted" just the calculator app you link? Of course I don't know how much complexity went into it, but maybe the app just didn't touch on the darker corners/pitfalls of SwiftUI that I find you only run into when it comes to Core Data, fancy views, animations/transitions and so on.
- math-dev 5y agoCore Data is a persistent storage facility so can be handled either in Swift or SwiftUI. I wrote a reasonably valued answer on controlling animations in SwiftUI on SO, so I was happy to push the boundaries there: https://stackoverflow.com/questions/58284994/swiftui-how-to-handle-both-tap-long-press-of-button https://stackoverflow.com/questions/58284994/swiftui-how-to-... The app doesn’t have any super advanced animation, but for most apps, I don’t think that is required. But that’s personal opinion. This is a longwinded way of saying perhaps you are right and I haven’t fully appreciated more advanced UI, but at the same time many of the basics in SwiftUI cover many use cases :)
- read_if_gay_ 5y ago> many of the basics in SwiftUI cover many use cases :) Yeah, I fully agree. But I also feel like if your use case isn't covered, you're losing much of the elegance, and I hope that's just because SwiftUI isn't fully mature yet. Sorry if I came across like I just thought your app was too basic. I was just trying to say that you might have happened to not run into any of SwiftUI's rough edges, no offense. Regarding Core Data of course you're right that it's not directly related to SwiftUI but interfacing with it from a SwiftUI app feels very un-SwiftUI-like. I hope they have something in the pipeline for WWDC.