Book Image

TypeScript High Performance

By : Ajinkya Kher
Book Image

TypeScript High Performance

By: Ajinkya Kher

Overview of this book

<p>In a world where a tiny decrease in frames per second impacts customer engagement greatly, writing highly scalable code is more of a necessity than a luxury. Using TypeScript you get type checking during development. This gives you the power to write optimized code quickly. This book is also a solid tool to those who’re curious to understand the impact of performance in production, and it is of the greatest aid to the proactive developers who like to be cognizant of and avoid the classic pitfalls while coding.</p> <p>The book will starts with explaining the efficient implementation of basic data Structures, data types, and flow control. You will then learn efficient use of advanced language constructs and asynchronous programming. Further, you'll learn different configurations available with TSLint to improve code quality and performance. Next, we'll introduce you to the concepts of profiling and then we deep dive into profiling JS with several tools such as firebug, chrome, fiddler. Finally, you'll learn techniques to build and deploy real world large scale TypeScript applications.</p>
Table of Contents (17 chapters)
Title Page
Credits
Foreword
About the Author
Acknowlegement
About the Reviewer
www.PacktPub.com
Customer Feedback
Preface
7
Profile Deployed JS with Developer Tools and Fiddler

Fiddler


Fiddler is a very popular web debugging tool that logs all the HTTP and HTTPS traffic between your system and the internet. Let's take a look at how we can use Fiddler to analyze the behavior and performance of our web application. Once again, let's use https://www.bing.com as an example.

Let's start by taking a look at how you can capture traffic with Fiddler:

Initial view of Fiddler showing the traffic capturing toggle on

As you can see in the preceding screenshot, there's a toggle at the bottom-left of the tool, which can be turned on and off so that you record traffic only for the duration you're interested in. Note that the the preceding screenshot does not show the complete UI of the tool. Fiddler contains several useful tabs, many of which we will explore shortly.

Let's initiate a search request on Bing now. First, let's start the traffic capture on Fiddler. Next, let's type "Mount Rainier" on Bing's search box and hit Enter. Let's go back to Fiddler and stop the traffic capture...