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

QR code component

@Yeison2017

Desktop design screenshot for the QR code component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison

SolutionDesign

Yeison Hernandez’s questions for the community

I wanted to implement the BEM methodology, but I'm not sure if I applied it correctly?

Is there a better way or methodology in naming the variables I use in :root?

Community feedback

P
ApplePieGiraffeβ€’ 30,545

@ApplePieGiraffe

Posted

Hi, Yeison Hernandez! πŸ‘‹

Congratulations on completing your first Frontend Mentor challenge! πŸŽ‰ Well done on this one! πŸ‘

Your BEM looks good! πŸ‘ One small suggestion I have is to set width: 100% on the card component instead of giving it a fixed width. Then, you can set a max-width of a specific value (like max-width: 19.5rem) to ensure that the card component doesn't become too wide. This will ensure that the width of the card can shrink in the space around it ever gets too small. πŸ™‚

As for naming things, it's really up to you and the people you are working with for what names you choose for things. The main thing to keep in mind is to find and use names that are easy to read and understand so that your code will be easy to read and understand, as well. The names you've chosen in your project look good to me! πŸ˜‰

Hope you find this helpful. 😊

Keep coding (and happy coding, too)! 😁

Marked as helpful

1
Imran Khanβ€’ 350

@astr0n0mer

Posted

Hi @Yeison2017, you're off to a great start

Some corrections as you're using BEM

  • The <div> with class="cardQR__content" is a block and should have its own name, maybe "content"
  • And then the children will be "content__title" and "content__info"

You can consider these resources for expanding your knowledge on BEM:

Good luck. Happy coding πŸ˜πŸ˜€

Marked as helpful

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join our Discord community

Join other Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord