Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.
Hana Kim2,162 Points
How do you determine all these numbers for your code when you are making your own website?
Just a quick question of curiosity...
The teacher is showing us how to code our own website, but when it comes down to making your own in the future, how will you know what numbers to put in your margin, padding and widths and so forth?
Is it that you would have to experiment a lot? Or is it that there is a set number out there for people to put in their code?
It all depends, really. It used to be 960px was the go to width, and I think like 10 or 20px of padding on the inside. Now, that's all changed as devices are so many with so many possible widths. As you learn more, you will get a feel for what fits, and in reality, you can set those numbers to anything you want. There are rules and style guides that you will learn that will help dictate how wide a section of your site should be. It's all part of the process. Hope that helps somewhat.