Phil's Weather App Journal

So I just finished my app for the monthly challenge, and because I totally forgot to write this journal, I will summarise my steps :slight_smile:

Day 1
I started by searching for ideas on how the app should look like, what features it should have and which API I’m going to use.
After a bit I decided to lean on the original weather app from IOS for the design, and OpenweatherMap over RapidAPI as the API.
Features should then be:

  • Current temperature + real feel
  • Current weather situation (cloudy,…)
  • Different measurement units
  • Textfield as entry for weatherlocation
  • hourly and daily preview

Then I started creating a first mockup view for the app with dummy items and dummy data

Day 2 - 4: I hate APIs and JSONs :wink:
On these day I wanted to write the code to receive and update the weather data.
On RapidAPI all Endpoints are free except the “16 day / daily forecast data” so i had to extract the daily data from the other endpoints (yeah I could searched for another API oder paid, but… nah, why make it easy? :slight_smile: ).
I decided to stay on the “5 day / 3 hour forecast data”, which gave me a good compromise.
And there it begun… writing code to get the data wouldn’t be thaaaaaat hard I thought…
I grabbed the Code Snippets from RapidAPI and watched CWCs Videos on APIs and JSON parsing, but I don’t know what I did… it just refused to work.

During mental breakdown from the API code, I decided to try something more easy and write code for a settings page to update the units or location data for the forecast.
This on the other hand was quite easy and gave me some hope back to finish this project :sweat_smile:

After some more time I eventually got the code for the API to work.
I guess the code looks quite messy, but it works, so I won’t touch it anymore…

Day 5
Now, that I have all the bits and pieces for the App, I started putting them together.
During “assembly” I realised, that extracting daily data from 3 hour timestamps of the API call wasn’t that easy so I had to come up with something else.
Instead of separating the hourly forecast from the dsfaily forecast, I just made a List where each item contains a 3 hour timestamp. After each day I put a Capsule() element to make the list easier to read.
Then some more minor polishing, and it was basically done. The last thing I needed was an Icon.


And there was it again… the part with creativity…
So I jumped in… yeah… pages and threw a gradient color square and an SF Symbol together which looked not that bad in the end :grin:

Conclusion
It was a really fun challenge which helped me to go out of my comfort zone with app building and learn new stuff :+1:
I think there are quite some improvements to make in my app (mostly the API part looks a bit sketchy I think) but I’m happy to have finally learned how to put something like that together.

2 Likes

Great job!! I’m a little jealous, this is exactly what I need to do, jump into an api build and get my hands dirty lol! I enjoyed reading your experience, hope you do the next challenge!

2 Likes