Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialKonrad Pilch
2,435 PointsHow should i start with the mobile first design?
HI,
Mobile first design first in head right? Recently iv been doing websites starting from desktop to mobile. But as Nick says, mobile first.
SO heres my question. How should i put it in CSS so its nice? should i do it like i did it on desktop? or should i do the same way but place the css in the media querry? e.g:
This is my normal template i start from , the names i change obeviously .
/*
My Custom CSS
============
Author:
Updated:
Notes:
Email:
*/
/* --------------------------------------
Index
-------------------------------------- */
/* --------------------------------------
Header
-------------------------------------- */
/* --------------------------------------
Focus
-------------------------------------- */
/* --------------------------------------
Experience
-------------------------------------- */
/* --------------------------------------
Portfolio
-------------------------------------- */
/* --------------------------------------
About
-------------------------------------- */
/* --------------------------------------
Contact
-------------------------------------- */
/* --------------------------------------
Footer
-------------------------------------- */
/* --------------------------------------
Media Queries
-------------------------------------- */
/* Portrait & landscape phone */
@media (max-width: 480px) {
}
/* Landscape phone to portrait tablet */
@media (max-width: 768px) {
}
/* Tablet desktop */
@media (min-width:768px) and (max-width:1110px){
}
Now, seen this, should i put the media queries under e.g Home? and start there with the sytiling for the mobile design? Or should i just put it here at the bottom and when i scale it up , the deskto desing put it wheres normal?
I rally want to write good code and structure. Plus im using bootstrap all the time. I can still make everything in CSS although i didnt try to do the grid system yet . I just feel using a framewokr for now its more convinient because im more focusing on back-end for now .