Book Image

Responsive Design High Performance

By : Els
Book Image

Responsive Design High Performance

By: Els

Overview of this book

This book is ideal for developers who have experience in developing websites or possess minor knowledge of how responsive websites work. No experience of high-level website development or performance tweaking is required.
Table of Contents (11 chapters)
7
7. Speeding Up Development with Design Concepts, Patterns, and Programs
10
Index

Combining files

Now that we can reduce the number of images that we request, why don't we reduce the resources that we use as well? Fewer files means a faster website.

When I started developing websites, I often requested two, three, or even four CSS files from the server. It never even crossed my mind to combine these files into one minified kilobyte-sized file. There isn't much here to do as the concept speaks for itself. When you use an application such as CodeKit or Compass.app, it is even easier to do this.

Your media queries and styles can all be in one file. A good practice is to split up the media queries and the main styles. If you're following the mobile-first methodology, you most probably do your mobile styles first and use the media queries to expand on your design, rather that diminishing your styles, and so on, in media queries.

The negative side of this is that, if you combine too many files, you could delay loading the rest of the website. So, find a balance...