Skip to content

DmytroTruten/Weather-App

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

59 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Weather App

This is a simple weather app that allows users to search for weather information by city name. It uses the OpenWeather API to retrieve weather data, and displays the current weather conditions, as well as a 3-hour and daily forecast.

Features

  • Search for weather information by city name
  • Display current weather conditions, including temperature, humidity, wind speed, and sunrise/sunset times
  • Display a 3-hour forecast and a daily forecast
  • Toggle between Celsius and Fahrenheit units

Technologies

This app was built using the following technologies:

Getting Started

To get started with this app, follow these steps:

  1. Clone this repository to your local machine.
  2. Run npm install to install the necessary dependencies.
  3. Obtain an API key from the OpenWeatherMap website.
  4. Create a .env file in the root directory of the project.
  5. Add your API key and API URL to the .env file, like this:
VITE_API_KEY = <your_api_key_here>
VITE_API_URL = https://api.openweathermap.org/data/2.5'

  1. Run npm run dev to start the development server.
  2. Navigate to http://localhost:5173 to view the app in your browser.

Usage

To use the app, simply enter the name of the city you want to search for in the input field and press the "Search" button or hit the "Enter" key. The app will display the current weather information for the selected city, along with the 3-hour and daily forecast.