Design comparison
Solution retrospective
Any feedback appreciated!
Community feedback
- @aykinsancakliPosted 9 months ago
Feedback on "Add to Cart" Button Element
Hey there!
I hope this message finds you well. While reviewing the code, one thing caught my eye. The "Add to Cart" button is currently implemented as a generic
div
element.In real-world scenarios, it's a good practice to use a
button
element for interactive elements with a specific action, such as adding a product to the cart. A simple rule to remember is: "If it does something, it is a button; if it directs you somewhere else, it is a link."Marked as helpful0@N4thxnPosted 9 months ago@aykinsancakli,
Thank you for the reply! I'll be sure to implement that into future challenges. I appreciate your feedback and will be sure to pass it along!
1
Please log in to post a comment
Log in with GitHubJoin 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