Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

Responsive E-commerce Page with NextJS/React, TypeScript & Tailwind

#next#react#tailwind-css#typescript
Francisldn 250

@francisldn

Desktop design screenshot for the E-commerce product page coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
3intermediate
View challenge

Design comparison


SolutionDesign

Solution retrospective


Challenges that I faced while building the project

Create Lightbox feature

  • This is my first attempt at coding a lightbox feature. I have referred to a youtube tutorial which provides ideas about different ways of closing a lightbox (ie. 'escape' key, clicking outside the lightbox). Through the process, I learnt how to use useCallback hook in combination with useEffect

Typescript errors

  • Also learnt about how to resolve typescript errors relating to useRef hook. Another instance of typescript error is different ways of typing event. In particular, I realised that I need to denote React.MouseEvent for onClick event type, and not just MouseEvent

Reusable React components and refactoring

  • Through the process, I gained a deeper understanding of ways to create re-usable components in React and how to refactor the code to keep it DRY.

Any comments / feedback would be much appreciated.

Community feedback

Please log in to post a comment

Log in with GitHub
Discord logo

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