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 trial

HTML How to Make a Website CSS: Cascading Style Sheets What is CSS?

Hussein Amr
Hussein Amr
2,461 Points

Why do we place the rules especially in the header!!? Why not some where else? stupid question sorry :/

that's just it

peyton caseria
peyton caseria
Courses Plus Student 12,281 Points

No problem, up vote my post so other users know its viable!

1 Answer

peyton caseria
PLUS
peyton caseria
Courses Plus Student 12,281 Points

When you start dealing with more than front end its considered best practice to put this resources inside the header, because they are easy to find.

Lots of the stuff like css in an html file using the replaces the need for a .css file correlating to said homepage, After it builds up there it gets hard to read so its better to make a separate file. All of that code is in one place only, where nothing but a works.

It is great for testing, but later down the road when you sell your application and the owners need to make adjustments it will make it impossible for them to find the files they are looking for to update, remove, edit and etc.

It's not a stupid question either!

I'm in a bootcamp right now for web development, my teachers are working on an app and its probably 100k characters long without a doubt, it is probably a million!

For convenience they use stuff such as this in html

So, when their teammate goes into it they can find what they need and change it without wasting an hour finding the thing and taking a break when they finally do!