Table of Contents

Copyright

Brief Table of Contents

Table of Contents

Preface

Acknowledgments

About this Book

1. Defining performance

Chapter 1. High-speed websites

1.1. Why optimize?

1.2. The financial impact

1.2.1. The business impact

1.2.2. The search engine ranking impact

1.2.3. The mobile user impact

1.2.4. The environmental impact

1.3. How to optimize

1.3.1. Profile

1.3.2. Identify

1.3.3. Implement

1.3.4. Monitor

1.4. Where to optimize

1.5. The Performance Golden Rule

1.6. Summary

Chapter 2. First steps toward a faster website

2.1. The basics of HTTP

2.1.1. Understanding an HTTP GET request

2.1.2. Understanding an HTTP GET response

2.1.3. Understanding HTTP status codes

2.2. Empty cache vs. primed cache

2.3. Tips and tools for interpreting performance charts

2.3.1. What does it all mean?

2.3.2. Google Chrome developer tools

2.3.3. Internet Explorer developer tools

2.3.4. Firebug

2.3.5. Safari Web Inspector

2.3.6. HTTPWatch

2.3.7. WebPagetest

2.3.8. Fiddler

2.4. Performance rules to live by

2.4.1. Yahoo! YSlow

2.4.2. Google PageSpeed

2.5. Summary

2. General performance best practices

Chapter 3. Compression

3.1. What is compression?

3.2. Why should I use compression?

3.3. Pros and cons of compression

3.4. Types of compression

3.4.1. Gzip

3.4.2. Deflate

3.4.3. SDCH

3.5. Accept-Encoding

3.6. The Surf Store application

3.7. Adding compression to your website

3.7.1. Using IIS to add compression to a website

3.7.2. Using a Web.config file to add compression to a website

3.7.3. Adding compression with other techniques

3.8. The results

3.9. Summary

Chapter 4. Caching: The sell-by date

4.1. What is HTTP caching?

4.2. IIS and HTTP caching

4.3. Web.config settings

4.4. Caching considerations

4.5. Output caching

4.5.1. Output caching in an ASP.NET MVC application

4.5.2. Output caching in an ASP.NET Web Forms application

4.6. The results of HTTP caching

4.7. Summary

Chapter 5. Minifying and bundling static files

5.1. What is minification?

5.2. What is bundling?

5.3. New bundling and minifying features in ASP.NET 4.5

5.4. Utilizing bundling in ASP.NET MVC

5.5. Utilizing bundling in ASP.NET Web Forms

5.6. The results

5.7. Summary

Chapter 6. HTML optimization tips

6.1. Where to position CSS and JavaScript in a web page to achieve the best performance

6.1.1. CSS

6.1.2. JavaScript

6.2. How the order of styles and scripts affects rendering

6.2.1. The impact of duplicate scripts

6.3. HTML5

6.4. A note on HTML5 browser support

6.4.1. HTML5 asynchronous JavaScript

6.4.2. HTML5 Web Workers

6.4.3. Browser support for HTML5 Web Workers

6.4.4. HTML5 Web Workers in an ASP.NET MVC application

6.4.5. Web Workers in an ASP.NET Web Forms application

6.5. HTML5 application cache

6.5.1. HTML5 application cache considerations

6.5.2. HTML5 application cache in an ASP.NET MVC application

6.5.3. HTML5 application cache in an ASP.NET Web Forms application

6.5.4. Application cache support

6.6. Summary

Chapter 7. Image optimization

7.1. What’s the big deal with image optimization?

7.2. Online image optimization tools

7.2.1. Smush.it

7.2.2. Kraken

7.3. Command line image optimization tools

7.3.1. Pngcrush

7.3.2. Jpegtran

7.4. Image Optimizer—a Visual Studio extension

7.5. Using data URIs

7.5.1. Implementing data URIs in an ASP.NET MVC application

7.5.2. Implementing data URIs in an ASP.NET Web Forms application

7.6. The importance of specifying image dimensions

7.7. The results

7.8. Summary

Chapter 8. ETags

8.1. What are ETags?

8.2. Why should I change ETags?

8.3. Removing ETags in ASP.NET Web Forms and ASP.NET MVC applications

8.4. The results

8.5. Summary

Chapter 9. Content Delivery Networks

9.1. What is a Content Delivery Network?

9.2. CDN options

9.3. Domain sharding

9.4. Developing with a CDN

9.4.1. ASP.NET MVC HTML helper for CDN development

9.4.2. ASP.NET Web Forms helper for CDN development

9.5. The results

9.6. Summary

3. ASP.NET–specific techniques

Chapter 10. Tweaking ASP.NET MVC performance

10.1. Using only the view engines that you need

10.2. Release mode vs. Debug mode

10.3. The importance of a favicon

10.4. Utilizing a code profiler

10.4.1. MiniProfiler for database profiling

10.5. Summary

Chapter 11. Tweaking ASP.NET Web Forms performance

11.1. HTML improvements

11.2. Web.config settings

11.2.1. Publishing your application in Release mode

11.2.2. Disable tracing if it’s not used

11.2.3. Disable session state

11.2.4. Disable ViewState when it’s not needed

11.3. Response.Redirect vs. Server.Transfer

11.4. Utilizing a code profiler

11.5. Fixing the issue

11.6. Summary

Chapter 12. Data caching

12.1. Server-side data caching

12.2. System.Runtime.Caching

12.3. What should I cache?

12.4. The sample application

12.5. Notes on distributed caching

12.6. Summary

12.7. Look at how far you’ve come!

 Appendix

A.1. Setting up your local machine as a web development server with IIS

A.2. Useful links referenced in this book

Profiling tools

Image optimization tools

Before and after results

Index

List of Figures

List of Tables

List of Listings

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset