Skip to content

helloswapnadeep/cloud-scout

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Here’s a tailored README.md for a weather web app built solely using HTML, CSS, and JavaScript:

# Weather Web App 🌦️

A simple and responsive weather web application that provides real-time weather updates and forecasts. Built using **HTML**, **CSS**, and **JavaScript**, this project is perfect for showcasing core web development skills and integrating external APIs.

🚀 Features

  • Real-Time Weather Updates: Displays current weather data including temperature, humidity, wind speed, and weather conditions.
  • City Search: Allows users to search for the weather of any city worldwide.
  • Responsive Design: Optimized for viewing on desktops, tablets, and mobile devices.
  • Weather Icons: Visual representation of weather conditions with dynamic icons.
  • API Integration: Fetches accurate weather data from the OpenWeatherMap API.

🌐 Live Demo

Check out the live app here: Weather Web App Live


🏗️ Installation and Setup

To run the project locally, follow these steps:

  1. Clone the repository:

  2. Open the project directory and locate the index.html file.

  3. Set up your API key:

  4. Open the index.html file in your browser to view the app.


📦 Folder Structure

weather-webapp/
├── index.html                      # Main HTML file
├── components/styles.css           # Styling for the app
├── components/scripts.js           # JavaScript for functionality
└── README.md                       # Project documentation

🛠️ Technologies Used

  • HTML5: Markup for the structure of the app.
  • CSS3: Styling and responsive design.
  • JavaScript (ES6): Logic for fetching and displaying weather data.
  • Weather API: Integrated with OpenWeatherMap API for real-time data.

💻 How It Works

  1. Users enter the name of a city in the search bar.
  2. The app fetches weather data for the city using the OpenWeatherMap API.
  3. Displays the following information:
    • Current temperature
    • Weather conditions (e.g., sunny, cloudy, rainy)
    • Humidity level
    • Wind speed
  4. Includes responsive styling for optimal viewing on all devices.

☢️ Important Announcement

# Fixing Asset Paths for Local Development

When working on a web project locally, you might encounter issues where images or fonts fail to load. This often happens because the asset paths in the code include a prefix specific to the production environment, such as `/cloud-scout`.

## Problem

In production, asset paths might look like this in your `.css` or `.js` files:

### Example
```css
background-image: url('/cloud-scout/assets/images/background.jpg');

```Font Family
src: url(/cloud-scout/fonts/iosevkanerdfontmono.ttf) format("truetype");

These paths work in production but fail on a local system because the /cloud-scout prefix doesn't exist in the local environment.

Solution

To fix this issue, remove the /cloud-scout prefix and use relative paths instead.

Updated Code

background-image: url('/assets/images/background.jpg');
src: url(/fonts/iosevkanerdfontmono.ttf) format("truetype");

Benefits of Using Relative Paths

  1. Local Compatibility: Assets will load correctly on your local system.
  2. Cross-Environment Consistency: The project will work seamlessly in both local and production environments.
  3. Simpler Maintenance: Relative paths are easier to manage during development and deployment.

Implementation Steps

  1. Open your .css or .js files.
  2. Search for paths containing /cloud-scout (or any other production-specific prefix).
  3. Replace these paths with relative paths starting from the project root or relevant directory.

Before

background-image: url('/cloud-scout/assets/images/background.jpg');
src: url(/cloud-scout/fonts/iosevkanerdfontmono.ttf) format("truetype");

After

background-image: url('/assets/images/background.jpg');
src: url(/fonts/iosevkanerdfontmono.ttf) format("truetype");

By making these adjustments, your project will be ready for local development without breaking asset loading functionality.


This is structured for a clear and professional GitHub `README.md` file and uses Markdown conventions effectively.

---
## 📄 License

This project is licensed under the [MIT License](LICENSE).

---

## 🤝 Contributing

Contributions are welcome! If you have suggestions or want to improve the app, feel free to fork the repository, make changes, and submit a pull request.

---

## 📧 Contact

For inquiries or support, contact:
- **Email**: [[email protected]](mailto:[email protected])
- **GitHub**: [helloswapnadeep](https://github.com/helloswapnadeep)

---

### ⭐ Don't forget to star this repository if you found it helpful!

This README is designed for a basic project using only HTML, CSS, and JavaScript. Adjust the content to reflect any additional features or personal preferences.