Design comparison
Solution retrospective
This is my second completed challenge and it has become apparent that I need to really focus on how to do responsive sites as this proved problematic in the development process. Any heads up on introductory lessons would be appreciated.
Community feedback
- @AgataLiberskaPosted over 3 years ago
Hi @antoniotullyspinozz! I think your solution looks pretty good :)
As for your question, I think you started with the desktop design and then adjusted it to mobile, am I right? It's generally a lot easier to start with the mobile layout - most of the content will be in a single column, so there's no need to reposition things - and then when there's enough space on the viewport, to move things around, introduce grid etc.
In your solution, I would also make sure that your background image on desktop doesn't repeat - you can use
background-repeat
property and thenbackground-size: cover
to make sure that the image is not smaller than the viewport :)1@antoniotullyspinozziPosted over 3 years agoThank you for your input. I started my next project by doing just that, starting with mobile design... and yes, you're right it tends to be easier to do it this way. However, something I hadn't considered is not even using grid in the mobile design but introducing it as you increase the viewport. So, thanks for the lesson.
Also, would there be a difference between
background-size: cover
andbackground-size: auto 100%;
?1@AgataLiberskaPosted over 3 years ago@antoniotullyspinozzi oh sorry, I was wrong then - I was guessing based on the max-width media queries. Anyway, I wasn't sure about the background size so I had a look on MDN - and yes there would be a difference, you can change the values in the demo on MDN to see it better - but basically if you use
cover
, parts of the image can be cropped off (or tiled, if you don't setbackground-repeat
) and withauto 100%
that won't happen. And now that I've done this challenge myself, I'm thinking that maybe the latter is actually a better option :D1
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