Skip to content

A dynamic and interactive quiz application that allows users to test their knowledge on various topics. Built with modern web technologies for an engaging user experience.

License

Notifications You must be signed in to change notification settings

Mman7/programmer-quiz

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

199 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Programmer Quiz

A comprehensive quiz application designed for programmers to test their knowledge across various programming topics and difficulty levels.

๐Ÿ–ผ๏ธ Screenshots

showcase 1 showcase 2 showcase 3

๐Ÿš€ Features

  • Multi-language Support: Quiz questions in C++, C#, JavaScript, React, Software Development, TypeScript, and Web Development
  • Difficulty Levels: Easy, Medium, and Hard difficulty options
  • Interactive UI: Modern, responsive design with intuitive navigation
  • Performance Tracking: Results analysis and performance charts
  • State Management: Efficient state handling using Zustand
  • Data Persistence: Cache management for improved performance

๐Ÿ› ๏ธ Tech Stack

  • Framework: Next.js 16.1.3 (App Router)
  • Language: TypeScript 5
  • UI Library: Tailwind CSS with DaisyUI components
  • State Management: Zustand
  • Charts: Chart.js with React Chart.js 2
  • Icons: Font Awesome
  • Performance: React 19.2.3, use-debounce

๐Ÿ“ Project Structure

src/
โ”œโ”€โ”€ app/                    # Next.js App Router pages
โ”œโ”€โ”€ components/            # Reusable UI components
โ”œโ”€โ”€ data/                  # Quiz question data files
โ”œโ”€โ”€ hooks/                 # Custom React hooks
โ”œโ”€โ”€ lib/                   # Utility libraries
โ”œโ”€โ”€ store/                 # Zustand global state stores
โ”œโ”€โ”€ types/                 # TypeScript type definitions
โ”œโ”€โ”€ utils/                 # Utility functions

๐ŸŽฎ How to Use

  1. Start the Development Server

    npm run dev
    # or
    yarn dev
    # or
    pnpm dev
    # or
    bun dev
  2. Access the Application Open http://localhost:3000 in your browser

  3. Navigation

    • Select topics of interest
    • Choose difficulty level
    • Start quiz and answer questions
    • View results and performance analysis

๐Ÿ“Š Quiz Sections

Available Topics

  • C++
  • C#
  • JavaScript
  • React
  • Software Development
  • TypeScript
  • Web Development

Difficulty Levels

  • Easy
  • Medium
  • Hard

๐Ÿ“ˆ Performance Analysis

The application includes:

  • Results page with detailed performance metrics
  • Data visualization using Chart.js
  • Topic-wise performance tracking

๐Ÿ“ฆ Dependencies

Core Dependencies

  • next: 16.1.3
  • react: 19.2.3
  • react-dom: 19.2.3
  • zustand: 5.0.10
  • chart.js: 4.5.1
  • daisyui: 5.5.14

Development Dependencies

  • typescript: 5
  • eslint: 9
  • tailwindcss: 4.1.18
  • prettier: 3.8.0

๐Ÿ“ Development

Available Scripts

npm run dev        # Start development server
npm run build      # Build for production
npm run start      # Start production server
npm run lint       # Run ESLint

Key Components

  • startGameModal - Initial quiz setup
  • quizPage - Main quiz interface
  • results - Performance analysis
  • sidebar - Topic selection
  • navbar - Navigation bar

State Management

  • useQuizGameStore - Quiz game state
  • useSelectedTopicsStore - Selected topics
  • useDifficultyModalStore - Difficulty selection
  • useStartModalStore - Start modal state
  • useDataStore - Data management
  • useComfirmModalStore - Confirmation modal

๐ŸŽจ Styling

  • Tailwind CSS: Utility-first CSS framework
  • DaisyUI: Component library built on Tailwind
  • Responsive Design: Mobile-first approach
  • Custom Themes: Tailwind configuration

๐Ÿ“Š Data Management

Data Sources

  • JSON files for each topic and difficulty level
  • Cache store for improved performance
  • Data validation and sanitization

Data Types

  • answer.d.ts
  • data.d.ts
  • quizGameOptions.d.ts
  • quizQuestion.d.ts
  • topic.d.ts

๐Ÿ”’ Security Considerations

  • Input validation for all user interactions
  • Secure API routes for quiz validation

๐Ÿš€ Deployment

Deploy to Netlify using the official deployment documentation: Next.js Deployment Documentation

๐Ÿ“„ License

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

๐Ÿ™ Acknowledgements


Built with Next.js, React, and TypeScript

About

A dynamic and interactive quiz application that allows users to test their knowledge on various topics. Built with modern web technologies for an engaging user experience.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages