Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted 4 months ago

Frontend Quiz App

react
P
Hector Ramirez•450
@hectorlil48
A solution to the Frontend Quiz app challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


What are you most proud of, and what would you do differently next time?

** What I’m Most Proud Of ** I’m most proud of how much I’ve learned and accomplished throughout this project. Despite feeling overwhelmed at times, I pushed through and developed an app that not only works as intended but also incorporates multiple React concepts and features. I’m proud of:

  • Tackling React from Scratch: I had to re-learn React after not using it for a while, and it felt great to see the progress I made, especially with passing props, managing state, and using hooks like useEffect.
  • Building a Functional and Interactive App: Creating a working quiz app with a dynamic user interface, dark/light mode toggle, and smooth transitions between questions was an achievement I’m proud of.
  • Deploying the App: Getting my app up on GitHub Pages was a big step for me, as it made everything feel more real and professional. Sharing my app with others gave me a sense of accomplishment.

** What I Would Do Differently Next Time ** While I’m proud of my work, there are a few things I’d approach differently next time:

  • Planning and Wireframing: I’d spend more time planning the app before starting. I didn’t do much wireframing, which made me jump into coding without a clear visual direction. This led to some unnecessary back-and-forth during the development process.
  • Handling State More Effectively: While I used props and state well, I feel I could have used Context API or Redux to manage state more efficiently, especially as the app grows and more features are added.
  • Testing Early: I didn’t implement testing during the development process, which in hindsight, would’ve been helpful to catch bugs earlier. Next time, I’ll start writing tests right from the beginning.
  • Design and UI/UX: Although I made the app functional, the design could have been more polished. I’d focus more on UI/UX principles and try to make the app look as good as it works.
What challenges did you encounter, and how did you overcome them?

** Challenges I Encountered and How I Overcame Them ** Throughout the development of my quiz app, I encountered several challenges, each of which taught me something valuable. Here’s how I navigated those obstacles:

  • Understanding React Basics: After not using React for a while, I found myself struggling to remember some of the core concepts. To overcome this, I watched tutorials and referred to the React documentation regularly. ChatGPT also helped me clarify doubts and explain concepts in simpler terms, allowing me to move forward with confidence.

  • Managing App State and Props: Passing props between components and managing state was tricky at first, especially as the app grew more complex. I overcame this by breaking down the app into smaller, reusable components and using props to pass data between them. I also practiced more with state management in React, which made me more comfortable with it over time.

  • Dark Mode/Light Mode Toggle: Implementing a theme toggle was more challenging than I initially thought. I had to manage CSS variables and ensure the switch worked smoothly across the entire app. By looking up examples and experimenting with localStorage to persist the theme across sessions, I was able to implement this feature successfully.

  • Handling onClick Events: As the app required multiple user interactions, handling onClick events properly was crucial. At times, I faced issues where event handlers weren’t firing as expected. I debugged these issues by checking my syntax and making sure the events were bound to the correct elements. Referring to Stack Overflow also helped me find solutions to common event handling issues.

  • Deploying to GitHub Pages: Deploying the app to GitHub Pages presented its own set of challenges, especially when dealing with routing and React's single-page application (SPA) nature. After some trial and error and reading through GitHub’s documentation, I found the solution to configure the app correctly for deployment. This process taught me a lot about deployment tools and the importance of understanding how they interact with your app.

What specific areas of your project would you like help with?

While I’ve made significant progress on my quiz app, there are still a few areas where I’d appreciate some guidance to improve and refine my work:

  • State Management with Context API or Redux: As the app expands, managing state across multiple components is becoming more challenging. I would love help understanding the best practices for using Context API or Redux to streamline state management and avoid prop drilling.

  • Testing the Application: I haven’t yet written tests for my app, and I’m unsure where to start. I’d like help with setting up testing frameworks like Jest or React Testing Library and writing effective tests to ensure my app works as expected.

  • UI/UX Design Improvements: While the app is functional, the design could use some refinement. I would appreciate feedback on improving the user interface and user experience, such as making it more intuitive, visually appealing, and accessible.

  • Performance Optimization: As the app grows and becomes more complex, performance could become an issue. I’d like help identifying potential bottlenecks and optimizing the app for better speed and responsiveness.

  • Deployment Best Practices: Although I deployed my app on GitHub Pages, I’d like to learn more about other deployment strategies (e.g., Netlify, Vercel) and how to set up Continuous Integration/Continuous Deployment (CI/CD) for smoother project management.

Code
Select a file

Please log in to post a comment

Log in with GitHub

Community feedback

  • P
    AnjelToppo•590
    @AnjelToppo
    Posted about 2 months ago

    One minor issue I found in your app is when you submit the wrong answer it still shows submit button and after clicking it, then shows next button. So, in conclusion in between these steps there is an extra step step came when you chose wrong option.

    In general, once you submit the wrong answer then it should display the wrong and correct option at once and in the same time it should also display next button.

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord
Frontend Mentor logo

Stay up to datewith new challenges, featured solutions, selected articles, and our latest news

Frontend Mentor

  • Unlock Pro
  • Contact us
  • FAQs
  • Become a partner

Explore

  • Learning paths
  • Challenges
  • Solutions
  • Articles

Community

  • Discord
  • Guidelines

For companies

  • Hire developers
  • Train developers
© Frontend Mentor 2019 - 2025
  • Terms
  • Cookie Policy
  • Privacy Policy
  • License

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

How does the accessibility report work?

When a solution is submitted, we use axe-core to run an automated audit of your code.

This picks out common accessibility issues like not using semantic HTML and not having proper heading hierarchies, among others.

This automated audit is fairly surface level, so we encourage to you review the project and code in more detail with accessibility best practices in mind.

How does the CSS report work?

When a solution is submitted, we use stylelint to run an automated check on the CSS code.

We've added some of our own linting rules based on recommended best practices. These rules are prefixed with frontend-mentor/ which you'll see at the top of each issue in the report.

The report will audit all CSS, SCSS and Less files in your repository.

How does the HTML validation report work?

When a solution is submitted, we use html-validate to run an automated check on the HTML code.

The report picks out common HTML issues such as not using headings within section elements and incorrect nesting of elements, among others.

Note that the report can pick up “invalid” attributes, which some frameworks automatically add to the HTML. These attributes are crucial for how the frameworks function, although they’re technically not valid HTML. As such, some projects can show up with many HTML validation errors, which are benign and are a necessary part of the framework.

How does the JavaScript validation report work?

When a solution is submitted, we use eslint to run an automated check on the JavaScript code.

The report picks out common JavaScript issues such as not using semicolons and using var instead of let or const, among others.

The report will audit all JS and JSX files in your repository. We currently do not support Typescript or other frontend frameworks.

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub