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

Using next js and tailwind css

Bartosz 10

@bartoopl

Desktop design screenshot for the Product preview card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I don't know how to add another photo to the mobile version.

Community feedback

@sarrietav-dev

Posted

Or you could use a media query with the background-image property.

This is the tailwind way to do it:

bg-[url('./image/*.jpg')] // For mobile

lg:bg-[url('./image/*.jpg')] // For desktop

Marked as helpful

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