Many technological devices have been created as a result of the advancement of modern society. One of them is a weather app that allows us to track the weather in our area and around the world. At the present, the number of weather observations has risen dramatically along with their quality. In this article, we look at a weather app totally made with Flutter using OpenWeatherAPI.
Generally, this weather app inspired by the beautiful and amazing designs made by Alyssa-Maree. Moreover, In this App, you can find live weather data in your current location, hourly weather, and 7-day weather forecasts for your device, as well as weather forecasts for any city you can think of!
What is used in this project
To begin with this weather app, we will discuss the materials used in this project below:
- How to use Dart to perform asynchronous tasks.
- Async and await.
- Network with the Dart http package.
- OpenWeatherAPI to get weather data using latitude, longitude and city
- JSONs and parse them using the Dart convert package.
- Pass data forwards and backwards between screens using the Navigator.
- Handle exceptions in Dart using try/catch/throw.
- Lifecycle of Stateful Widgets and override them.
- Geolocator package to get live location data for both iOS and Android.
- TextField Widget to take user input.
- Spinner to show to user while the data loads.
- Day and Night UI colour change dynamically.
- ExpansionPanelList view.
You should pay attention to the following important features:
- Feels like temperature
- Max temperature
- Wind speed
- Day/night mode
- Search weather by city
- Get current weather on clicking on ‘place icon’
- Hourly Weather Forecast with dynamic temperature, weather icon and time in horizontal scrolling
- Get Autocomplete list of cities as you type using Google Places API
- Google Places API for searching city name.
- 7 Day Weather Forecast