Responsive Columns preview card using grid-Template
Design comparison
Solution retrospective
Any Feedback about code and How to make it so clean and semantic :-)
Community feedback
- @Bayoumi-devPosted over 2 years ago
Hey Zienab, It looks good!...
- I suggest you change this
<div class="button">LearnMore</div>
...
Should be button to add more
semantics
to your project...Buttons
are used for actions.<button class="button">LearnMore</button>`
I hope this is useful to you... Keep codingπ
0@zenab12Posted over 2 years ago@Bayoumi-dev but we should use
<form>
to wrap<button>
inside it to make it right and more semantic . So I used div.button instead . If I misunderstand . Can you explain the correct explanation for me π0@Bayoumi-devPosted over 2 years ago@zenab12 I agree with you, the
button
outside of a<form>
is useless but even if a<button>
doesn't do anything outside of a form without the help of JavaScript, it still feels better for things you can click that do actions, So<button>
feels better anyway, and in this case, you also can use an anchor link<a>
instead of thebutton
... like this<a href="#" class="button" role="button">LearnMore</a>
, So When to use thebutton
and when to use theanchor link
???!... It depends on what you want to happen after clicking... will it redirect the user to another page or section? Use theanchor link
<a> Otherwise, use thebutton
- Buttons are used for actions like opening or closing something or sending a form.
- Links are used for navigation and actions.
If I'm wrong about something, it would be great if you could explain it to me.
Marked as helpful1@zenab12Posted over 2 years ago@Bayoumi-dev that's awesome ππ. Thanks so much for these Great tips
0 - I suggest you change this
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