Responsive product page using React and TypeScript

Solution retrospective
I am proud of my approach to this project to treat it as a smaller part of a larger e-commerce site. I accessed product data as though it came from a remote API or a full stack backend. I used TypeScript to define a Product
type and this helped improve consistency in data access and use.
I am also proud of my use of component props to make several of the project's components more modular, reusable, and composable. The best example of this is ImageViewer.tsx
that contains several optional props that can show and hide different elements of the component when they are/are not needed.
During this project I underestimated some of the requirements for state management and what other elements my components would need. I often found myself refactoring a component or function that I had written previously. In these cases, I took a chance to step back and re-evaluate why I had written a function or component in a particular way and what I would need to do to adapt it to the projects evolving needs.
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on James Spears's solution.
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