This is a solution to the E-commerce product page challenge on Frontend Mentor. Frontend Mentor challenges help you improve your coding skills by building realistic projects.
Note: Delete this note and update the table of contents based on what sections you keep.
Users should be able to:
- View the optimal layout for the site depending on their device's screen size
- See hover states for all interactive elements on the page
- Open a lightbox gallery by clicking on the large product image
- Switch the large product image by clicking on the small thumbnail images
- Add items to the cart
- View the cart and remove items from it
- Solution URL: Ecommerce github repo
- Live Site URL: Ecommerce
- Semantic HTML5 markup
- CSS custom properties
- Flexbox
- CSS Grid
- Mobile-first workflow
- Tailwindcss Framework
Use this section to recap over some of your major learnings while working through this project. Writing these out and providing code samples of areas you want to highlight is a great way to reinforce your own knowledge.
To see how you can add code snippets, see below:
// Checking if a button is active
thumbBtns.forEach(thumb => {
thumb.addEventListener('click',()=>{
thumbBtns.forEach(btn => btn.classList.remove('active-thumbnail'));
thumb.classList.add('active-thumbnail');
}
}
- Tailwind CSS - Tailwind Docs. I really like the documentation of the tailwind css framework.
- Website - [Oluwafemi Olukoya]
- Frontend Mentor - @Oluwafemi21
- Twitter - @femi_io
Special thanks to my friends who assisted my javascript implementation KeneNwogu and AjukaDavid.