Markus Bergh Bright Created with Sketch. Bright Created with Sketch.

SpaceX

Get details about rocket launches by SpaceX

Description.

Built with SwiftUI, I made an app to teach myself a bit more about GraphQL. I had previously only been experimenting with it using Node.js and wanted to give it a try on iOS.

Thankfully the team at Apollo has created a great GraphQL client that made it fun & easy to write fulfilling queries. By using the client I was able to list data about SpaceX launches. The data is fetched from an open API that I found.

Even if the app is very basic, I had great learnings with asking for & displaying data using GraphQL. The advantages with having a defined data shape—that is strongly typed—works really well with Swift. It was also easy to structure my code as I knew explicitly what data I was asking for, and thus I did no over-fetching that could happen easily by using REST.

Consider GraphQL an alternative when building a type-safe bridge from client to server. There are already many clients available, getting you quickly up to speed to test it out.

Demonstration of navigating through the views available in the iOS app.

Next project
Beckmans BFA Graduation