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

HTML and CSS file using CSS Grid and separate stylesheets

@AntonioHouTX

Desktop design screenshot for the Single price grid component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I have two related questions:

-Was it better for me to have created two separate stylesheets for both the mobile and desktop versions of this site, or would it have been better to have one stylesheet with two media queries in it? -Since I did the former option and not the latter, did I get the HTML stylesheet reference right in the "min-width" and "max-width" part?

Community feedback

@SeyBoo

Posted

Hello !

  • You should start the design Mobile or Desktop first and add media queries when it's not working.

  • One or two files is as you prefer but if you like cut your code in multiple files i will recomend you SCSS.

I hope this help have a nice day !

1
P
Grace 27,870

@grace-snow

Posted

Hi did you forget to do a mobile version for this? I'm only seeing the desktop one on my mobile

0

P
Grace 27,870

@grace-snow

Posted

@grace-snow ah I see it's because you've put your mobile media query in a min-width.

Your mobile styles should always be the default if you're going to split stylesheets. Because you don't want people on mobile devices, probably with smaller bandwidth to have to download everything for desktop as well.

And you won't want to do min and max width media queries on the css include as you'll. End up with problems like this - under 374px -has not been accounted for

0

@AntonioHouTX

Posted

@grace-snow Thanks for pointing this out. I'll make changes to the code accordingly. Much appreciated!

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