Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted 9 months ago

QR code card using tailwindcss

tailwind-css
P
NunoJDMachado•220
@NunoJDMachado
A solution to the QR code component challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


What are you most proud of, and what would you do differently next time?

Things I'm proud of:

  • Learning to install tailwindcss on a new project
  • Using flexbox efficiently
  • Extending custom CSS classes to tailwindcss

Things I'd do differently next time:

  • Avoid fixed widths
  • Download font files from google fonts
What challenges did you encounter, and how did you overcome them?
  • Tried installing tailwindcss using vite but ran into some error. Using tailwind CLI worked.

  • Was initially using classes like w-1/4, w-1/2, etc., but noticed that on smaller screen sizes the card was getting too narrow. Went for fixed width instead.

What specific areas of your project would you like help with?
  • I would like to know whether this approach of using fixed widths is valid. I just tried to eyeball the width of the card from the design screenshot and typed some width in pixels. Upon testing it seems to be working on all screen sizes, but surely there must be a more optimal way? Is there a better practice like using min width, percentages or something?
Code
Loading...

Please log in to post a comment

Log in with GitHub

Community feedback

No feedback yet. Be the first to give feedback on NunoJDMachado's solution.

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

Stay up to datewith new challenges, featured solutions, selected articles, and our latest news

Frontend Mentor

  • Unlock Pro
  • Contact us
  • FAQs
  • Become a partner
  • Use cases

Explore

  • Learning paths
  • Challenges
  • Solutions
  • Articles

Community

  • Discord
  • Guidelines

For companies

  • Hire developers
  • Train developers
© Frontend Mentor 2019 - 2025
  • Terms
  • Cookie Policy
  • Privacy Policy
  • License