Skip to content

sagar-1m/JavaScript-DOM-Challenges

Repository files navigation

🚀 JavaScript DOM Challenges

A comprehensive collection of interactive DOM manipulation challenges designed to help developers master JavaScript DOM operations through hands-on practice.

Project Banner

Deployment Status Last Commit License: MIT

📋 Overview

This project contains 11 progressive challenges focused on DOM manipulation techniques using vanilla JavaScript. Each challenge is designed to teach specific concepts while building practical components that you might use in real-world web applications.

Live Demo | Source Code

Screenshot of the application

🎯 Challenges

# Challenge Concepts Covered Preview
1 Light Bulb Toggle Event listeners, DOM state management 💡
2 Change Text Color DOM style manipulation, event handling 🦎
3 Real-time Form Input Display Form events, DOM updates, input handling 📋
4 Task Management CRUD operations, local storage, event delegation 🧏🏻‍♂️
5 Image Carousel Timers, CSS transitions, DOM traversal 🖼️
6 Enhanced Clock Date object, requestAnimationFrame, SVG manipulation
7 Accordion DOM traversal, animations, event handling 🪗
8 Simple Shopping Cart State management, event delegation, DOM updates 🛒
9 Sliding Menu CSS transitions, event handling, accessibility 🪟
10 Memory Card Game Array manipulation, DOM creation, game logic 🂫
11 Color Button Creator Closures, dynamic element creation, color management 🎨

🌟 Key Features

  • Progressive Difficulty: Start with simple challenges and advance to more complex ones
  • Real-world Components: Build UI components used in modern web applications
  • Vanilla JavaScript: No frameworks or libraries - pure DOM manipulation
  • Responsive Design: All challenges work across different screen sizes
  • Accessibility Features: Focus states, keyboard navigation, and ARIA attributes
  • Dark Mode Support: Light and dark theme options

📚 Learning Outcomes

  • DOM selection and traversal techniques
  • Event handling and delegation
  • Dynamic content creation and manipulation
  • State management in vanilla JavaScript
  • UI component development
  • Responsive design implementation
  • Accessibility best practices

🛠️ Technologies

HTML5 CSS3 JavaScript

💻 Getting Started

Prerequisites

  • A modern web browser (Chrome, Firefox, Safari, or Edge)
  • Basic knowledge of HTML, CSS, and JavaScript
  • Code editor (VS Code, Sublime Text, etc.)

Installation

  1. Clone the repository:

    git clone https://github.com/sagar-1m/JavaScript-DOM-Challenges.git
  2. Navigate to the project directory:

    cd JavaScript-DOM-Challenges
  3. Open the landing page to navigate through challenges:

    open index.html  # On macOS
    # Or simply double-click index.html in your file explorer

Challenge Structure

Each challenge follows this structure:

challenge-X/
├── index.html      # HTML structure
├── styles.css      # Challenge-specific styling
├── script.js       # JavaScript implementation

🤝 Contributing

Contributions are welcome! Here's how you can contribute:

  1. Fork the repository
  2. Create your feature branch: git checkout -b feature/new-challenge
  3. Add your challenge following the project structure
  4. Commit your changes: git commit -m 'Add new challenge: Name'
  5. Push to the branch: git push origin feature/new-challenge
  6. Open a Pull Request

Please ensure your code follows the project's style and includes appropriate documentation.

📄 License

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

🙏 Acknowledgments


Created with 💻 by Sagar Maheshwari

GitHub LinkedIn X