In this video Iftach Bar shows a tool called ng-stats and explains why it is very useful when debugging performance in Angular.
- [Instructor] : Another tool I love to use…is called ng-stats.…This tool allows you to see how much time…the last digest look took, and…how many watchers currently exist in your app.…It is a great tool to get the wide understanding…of where a performance problem might be.…To use it, I'm going to search it in Google.…Just search "ng-stats".…I'm going to go to this link…and I'm going to scroll down a bit.…
I'm going to reach the bookmarklet,…and I'm going to copy the whole bookmarklet.…In Chrome, I click the Bookmarks menu…and go to Bookmark Manager,…click on Organize,…and click Add Page.…I'm going to name it "ng-stats".…In the URL, I'm going to paste what I just copied.…Let's close it.…And close this.…Now, to use ng-stats, all I need to do…is click the bookmark I just saved.…
Notice what happens.…We can see on the left side the number of watchers…I currently have in my app, and on the right side…we see the time the last digest look took.…If we're going to click a button here,…or we're going to change the volume of force in the input,…
This advanced AngularJS course helps you explore the connected worlds of $scope and the digest cycle. Instructor Iftach Bar explains scope and inheritance, goes behind the scenes of the digest loop, and teaches both manual and automatic data binding approaches. Plus, learn how to integrate external libraries, diagnose performance issues, and debug your applications.
- $scope and controllers
- $scope built-in variables and methods
- $scope prototype inheritance
- Manual data binding with $scope.$watch
- The digest loop
- Get the $scope in the console
- Forcing $digest
Skill Level Advanced
AngularJS 1: Building a Data-Driven Appwith Ray Villalobos2h 15m Intermediate
1. Scope Basics
2. Manual Data Bindings
3. The Digest Loop
4. Tips for Debugging Angular in the Console
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.