DevQuiz is an interactive web application that allows users to test their programming knowledge through dynamic quizzes.
- Open the application
- Choose a quiz
- Answer the questions
- View your results
- Try again or explore other quizzes
- 📋 Quiz list with descriptions and difficulty levels
- 🎯 Interactive quiz flow with multiple questions
- 🔀 Randomized answer order for each question
- ⏱️ Built-in timer for tracking completion time
- 📊 Results summary (correct / incorrect answers)
- 💾 LocalStorage support for saving completed quiz results
- 🎞️ Smooth UI animations (on render and scroll)
src/js/
├── logic/
│ └── QuizEngine.js # Handles quiz logic: saving answers, calculating results and summary
│
├── mappers/
│ └── mapData.js # Transforms API data into a format suitable for the UI
│
├── modules/
│ ├── CarouselModule.js # Controls quiz navigation (slides, progress)
│ ├── PopupModule.js # Manages opening and closing of the quiz modal
│ ├── QuizModule.js # Main application flow (load list, start quiz, handle interactions)
│ └── TimerModule.js # Handles quiz timer (start, stop, update time)
│
├── services/
│ └── quizService.js # Fetches quiz data from API
│
├── ui/
│ └── QuizUI.js # Responsible for rendering UI elements and updating the DOM
│
├── utils/
│ ├── EventBus.js # Event system for communication between modules
│ ├── getData.js # Helper for making API requests
│ ├── quizResultsStorage.js # Saves and retrieves quiz results from localStorage
│ ├── ScrollAnimation.js # Handles scroll-based animations (Intersection Observer)
│ ├── setYear.js # Sets current year in the footer
│ └── shuffleArray.js # Shuffles answers (Fisher–Yates algorithm)
│
├── app.js # Entry point: initializes all modules and starts the app
├── config.js # Application configuration (API URL)
├── data.js # Static data (quizzes, main info, error message)
└── state.js # Global state (questions, answers, current quiz)
- Webpack
- JavaScript (ES6+)
- HTML5
- SCSS
- QuizAPI
git clone https://github.com/lvog/dev-quiz.gitcd dev-quiznpm installAdd your API key:
API_KEY=your_api_key_hereYou can get an API key by registering at QuizAPI
npm run devnpm run buildDistributed under the MIT License. See LICENSE for more information.
- Email: levchuk.oleg21@gmail.com
- Website: lvog.github.io
- LinkedIn: in/oleg-levchuk-2098b2b7