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

nft preview card componet with webpack and sass

P
EHO 265

@hermannleboss

Desktop design screenshot for the NFT preview card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I make everything ok. Thanks to everyone who will find something to add. A And thank to everyone who will review it.

Community feedback

P

@12Kentos

Posted

Hey @hermannleboss,

Nice job on the project, looks great! I noticed in your scss file you selected some of your elements directly like so.

a{ text-decoration: none; color: white; &:hover{ color: #00FFF8; }

While this isn't a big deal for small projects like this, generally it's not a good idea as this would select every single a element you have and apply those styles. I would highly suggest using a class directly, or using a class and then using the element to select your elements, as this will help you avoid a lot of headache in the future on larger projects.

Keep up the great work!

Marked as helpful

1

P
EHO 265

@hermannleboss

Posted

@12Kentos Hello, thanks for your advice. I moov colors specs into a css. Should use class for all style spec for elements ? Usually we have element that have some global style. Like paragraphe style. And then somme ones have a specify style. Did i need to use only class selector ?

0
P

@12Kentos

Posted

@hermannleboss If you want it to affect every single element you can use the element itself, like in the example I gave. But rarely will every element have the exact same style on the same page. A lot of them will have similar styles, which is why it's nice to give them a class. For instance most buttons will have a similar width/height/border radius on a page for consistency. So if you give it a class of .btn for example, you can easily reuse this code for all of the buttons you want to look alike on the page.

However if you wanted to make a new button, if you didn't use a class you would have to do a lot of style resets to get it looking the way you want. I hope that makes sense?

0
P
EHO 265

@hermannleboss

Posted

@12Kentos OK thanks

0

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