The Weather App is a simple command-line application that fetches and displays current weather information using the OpenWeatherMap API.
- Displays temperature, weather description, humidity, and wind speed for a specified city.
- Defaults to New York if no city name is provided as an argument.
-
Clone the repository or download the
weather.jsfile. -
Sign up for a free API key from OpenWeatherMap if you don't have one.
-
Replace
'YOUR_API_KEY'in theweather.jsfile with your OpenWeatherMap API key. -
Open a terminal and navigate to the directory containing
weather.js. -
Run the Weather App:
node weather.js
To specify a different city, provide the city name as an argument:
node weather.js London
- The default temperature unit is Celsius. You can customize the units in the API request URL by modifying the
unitsparameter.
- This project uses the OpenWeatherMap API to retrieve weather data.
Feel free to enhance this README with additional information, screenshots, or any other relevant details. Make sure to keep your API key secure and consider using environment variables to store sensitive information.