Skip to content

About

🌀️ SkyCast Weather App – A modern, responsive weather application built with React + TypeScript. Get real-time weather updates, 5-day forecasts, hourly trends, and a smooth UI with light/dark themes, smart city search, and auto-location detection.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

SkyCast Weather App 🌀️

A modern, responsive weather application built with React, TypeScript, and Vite. SkyCast provides real-time weather information, detailed forecasts, and an intuitive user experience with support for favorite cities and search history.

SkyCast Weather App TypeScript Vite TailwindCSS

✨ Features

🌍 Weather Information

  • Current Weather: Real-time weather conditions with temperature, humidity, wind speed, and more
  • 5-Day Forecast: Detailed weather predictions for the next 5 days
  • Hourly Temperature: 24-hour temperature trends with interactive charts
  • Weather Details: Comprehensive weather metrics including feels-like temperature, visibility, pressure, and UV index

πŸ™οΈ Location Services

  • Geolocation Support: Automatic detection of user's current location
  • City Search: Smart search functionality with autocomplete suggestions
  • Favorite Cities: Save and quickly access up to 10 favorite locations
  • Search History: Track recent searches for quick access

🎨 User Experience

  • Dark/Light Theme: Toggle between themes with system preference detection
  • Responsive Design: Optimized for desktop, tablet, and mobile devices
  • Loading Skeletons: Smooth loading states for better user experience
  • Error Handling: Graceful error handling with informative messages
  • Real-time Updates: Automatic data refresh and manual refresh options

πŸš€ Quick Start

Prerequisites

  • Node.js (version 18 or higher)
  • pnpm (recommended) or npm

Installation

  1. Clone the repository

    git clone <repository-url>
    cd skycast-weather-app
  2. Install dependencies

    pnpm install
    # or
    npm install
  3. Environment Setup Create a .env file in the root directory:

    VITE_OPENWEATHER_API_KEY=your_openweather_api_key_here

    Get your free API key from OpenWeatherMap

  4. Start the development server

    pnpm dev
    # or
    npm run dev
  5. Open your browser Navigate to http://localhost:5173 to view the application

πŸ› οΈ Available Scripts

Script Description
pnpm dev Start development server
pnpm build Build for production
pnpm preview Preview production build
pnpm lint Run ESLint

πŸ—οΈ Tech Stack

Core Technologies

State Management & API

Styling & UI

Routing & Navigation

Additional Libraries

πŸ“ Project Structure

src/
β”œβ”€β”€ app/                            # Redux store configuration
β”‚   β”œβ”€β”€ config.ts                   # API configuration
β”‚   └── store.ts                    # Redux store setup
β”œβ”€β”€ assets/                         # Static assets
β”‚   β”œβ”€β”€ logo-dark.png
β”‚   └── logo-light.png
β”œβ”€β”€ components/                     # Reusable components
β”‚   β”œβ”€β”€ ui/                         # Base UI components (shadcn/ui)
β”‚   β”œβ”€β”€ skeletons/                  # Loading skeleton components
β”‚   β”œβ”€β”€ CitySearch.tsx              # City search functionality
β”‚   β”œβ”€β”€ CurrentWeather.tsx          # Current weather display
β”‚   β”œβ”€β”€ Header.tsx                  # Application header
β”‚   β”œβ”€β”€ Layout.tsx                  # Main layout wrapper
β”‚   └── ...                         # Other components
β”œβ”€β”€ context/                        # React contexts
β”‚   └── theme-provider.tsx          # Theme context
β”œβ”€β”€ features/                       # Feature-based modules
β”‚   └── api/                        # API slices
β”‚       β”œβ”€β”€ geoApiSlice.ts          # Geocoding API
β”‚       └── weatherApiSlice.ts      # Weather API
β”œβ”€β”€ hooks/                          # Custom React hooks
β”‚   β”œβ”€β”€ use-favorite.tsx            # Favorite cities management
β”‚   β”œβ”€β”€ use-geolocation.tsx         # Geolocation handling
β”‚   β”œβ”€β”€ use-locale-storage.tsx      # Local storage wrapper
β”‚   └── use-search-history.tsx      # Search history management
β”œβ”€β”€ lib/                            # Utility functions
β”‚   └── utils.ts                    # Common utilities
β”œβ”€β”€ pages/                          # Page components
β”‚   β”œβ”€β”€ city-page.tsx               # Individual city page
β”‚   └── weather-dashboard.tsx       # Main dashboard
β”œβ”€β”€ types/                          # TypeScript type definitions
β”‚   β”œβ”€β”€ forecast.ts                 # Forecast data types
β”‚   β”œβ”€β”€ geocoding.ts                # Geocoding types
β”‚   β”œβ”€β”€ location.ts                 # Location types
β”‚   β”œβ”€β”€ search-history.ts           # Search history types
β”‚   β”œβ”€β”€ weather.ts                  # Weather data types
β”‚   └── index.ts                    # Type exports
β”œβ”€β”€ App.tsx                         # Root component
β”œβ”€β”€ index.css                       # Global styles
└── main.tsx                        # Application entry point

πŸ”§ Configuration

Environment Variables

  • VITE_OPENWEATHER_API_KEY - Your OpenWeatherMap API key

API Configuration

The app uses OpenWeatherMap API for weather data and geocoding. Configuration is managed in src/app/config.ts.

Theme Configuration

Supports automatic system theme detection with manual override. Themes are managed through the ThemeProvider.

πŸ“± Features in Detail

Weather Dashboard

  • Real-time weather conditions for user's current location
  • Comprehensive weather details and metrics
  • 5-day weather forecast with daily highs/lows
  • Hourly temperature chart for the next 24 hours
  • Quick access to favorite cities

City Search & Management

  • Intelligent city search with autocomplete
  • Search history tracking (last 10 searches)
  • Favorite cities management (up to 10 favorites)
  • Quick navigation between cities

Data Management

  • Efficient caching with RTK Query
  • Automatic data refresh every 5 minutes
  • Manual refresh capability
  • Offline-first approach with cached data

🎨 Design System

The application uses a modern design system built on:

  • TailwindCSS for utility-first styling
  • Radix UI for accessible component primitives
  • Custom component library following design patterns
  • Consistent spacing and typography scales
  • Responsive breakpoints for all device sizes

πŸ” Browser Support

  • Chrome (latest)
  • Firefox (latest)
  • Safari (latest)
  • Edge (latest)

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ™ Acknowledgments

πŸ“ž Support

If you encounter any issues or have questions, please:

  1. Check the Issues page
  2. Create a new issue with detailed information
  3. Include screenshots if applicable

Built with ❀️ using React, TypeScript, and modern web technologies.

About

🌀️ SkyCast Weather App – A modern, responsive weather application built with React + TypeScript. Get real-time weather updates, 5-day forecasts, hourly trends, and a smooth UI with light/dark themes, smart city search, and auto-location detection.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages