Skip to content

Davislyu/WeatherApp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 

Repository files navigation

Weather App

Description

This Weather App is a comprehensive React application that provides real-time weather information and forecasts. The app utilizes Redux for state management and AccuWeather API for fetching weather data. Key features include searching for weather by city, viewing current weather conditions, a five-day forecast, and managing favorite locations.

Features

  • Real-time Weather Data: Fetches and displays current weather conditions using the AccuWeather API.
  • Five-day Forecast: Offers a detailed 5-day weather forecast.
  • City Search with Autocomplete: Implements an autocomplete feature for searching cities.
  • Favorite Locations: Allows users to save and view their favorite weather locations.
  • Unit Conversion: Toggle between Celsius and Fahrenheit temperature units.
  • Responsive Design: The UI is responsive and adapts to different screen sizes.
  • Error Handling: Implements error handling for API requests and displays user-friendly messages.

Technologies

  • React.js
  • Redux Toolkit
  • Axios for API requests
  • Headless UI for autocomplete functionality
  • Material Tailwind for UI components
  • React Icons for iconography
  • React Hot Toast for notifications
  • React Router for navigation

Setup and Installation

  1. Clone the repository.
  2. Install dependencies using npm install.
  3. Set up environment variables:
  4. Run the application using npm start.

Usage

  • Viewing Weather: Enter a city in the search bar to view the current weather and a five-day forecast.
  • Adding Favorites: Click the 'Save' button on a weather card to add the location to your favorites.
  • Viewing Favorites: Navigate to the 'Favorites' tab to view saved locations.
  • Toggling Temperature Units: Use the switch in the navbar to toggle between Celsius and Fahrenheit.

Contributing

Contributions to the Weather App are welcome. Please follow these steps to contribute:

  1. Fork the repository.
  2. Create a new branch for your feature.
  3. Commit your changes.
  4. Push to the branch.
  5. Open a pull request.

ScreenShots

fullscreen

daytime

night

favorites

responsive