https://github.com/alexlopezdevelop/weatherapp
https://github.com/alexlopezdevelop/weatherapp
Last synced: 11 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/alexlopezdevelop/weatherapp
- Owner: AlexLopezDevelop
- Created: 2023-07-02T13:55:59.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2024-10-28T08:04:47.000Z (over 1 year ago)
- Last Synced: 2025-03-04T16:48:37.955Z (over 1 year ago)
- Language: Swift
- Size: 1.43 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Weather App
This is a weather application developed in Swift that queries a weather service to obtain the user's current location and displays the weather forecast in the device's language.

## APIs Used
This application utilizes the [OpenWeatherMap One Call API](https://openweathermap.org/api/one-call-api) to access weather information.
## Requirements
- Swift 5.0 or later
- Xcode 11.0 or later
## Installation
1. Clone the repository to your local machine.
2. Open the project in Xcode.
3. In the project navigator, locate the `Development.xconfig` file.
4. Open the `Development.xconfig` file and add your API key from [OpenWeatherMap](https://openweathermap.org/api/one-call-api) in the following format:
```
API_KEY = // Add your API key
```
Replace `// Add your API key` with your actual API key.
5. Save the `Development.xconfig` file.
6. Build and run the application in Xcode.
## Language Support
The Weather App supports the following languages:
- English πΊπΈ
- Spanish πͺπΈ
- French π«π·
To change the language of the app, ensure that your device is set to one of the supported languages.
## License
This project is licensed under the [MIT License](LICENSE).
## Comments
- `enableLocationView` has been created to showcase how to build a view without using Storyboards. However, the rest of the project has been developed using Storyboards and XIBs, as they are what I'm most accustomed to and allowed me to progress more quickly.
- No external libraries have been used, so there was no need for CocoaPods. In my opinion, it's generally better to rely on the tools provided by the Swift API, as it avoids dependency issues that may arise when migrating the app to a newer Swift version. However, in the part where obtaining the city name from the user's location, it could be improved by implementing a library that handles all possible cases. Unusual scenarios have been tested, such as locations in the northern part of Greenland, where the city name may not be available due to limited data.
- The `.xcconfig` file has been added to store the ApiKey, providing convenience for configuration purposes.