@@ -26,21 +26,21 @@ Read [Code Snippets tutorial][1],
2626[ Performance profiling using DevTools code snippets] [ 2 ] and
2727[ How to improve Angular application performance using code snippets] [ 3 ] .
2828
29- Note: code snippets do NOT have access to the full console API, for example no access to
29+ Note: code snippets do NOT have access to the full console API, for example no access to
3030` console.monitor ` .
3131
3232## Snippets
3333
3434### DOM and CPU generic performance
3535
36- * [ boilerplate.js] ( boilerplate.js ) - boilerplate for loading and running a remote code script
36+ * [ boilerplate.js] ( boilerplate.js ) - boilerplate for loading and running a remote code script
3737(see [ remote download] ( #remote-download ) ).
3838* [ first-paint.js] ( first-paint.js ) - time from page reload to first visible contents.
39- * [ timing.js] ( timing.js ) - Detailed page timing information,
39+ * [ timing.js] ( timing.js ) - Detailed page timing information,
4040from [ addyosmani/timing.js] ( https://github.com/addyosmani/timing.js ) .
4141* [ time-method-call.js] ( time-method-call.js ) - measures single method call time.
4242* [ profile-method-call.js] ( profile-method-call.js ) - profiles a single method call.
43- * [ profile-prototype-method.js] ( profile-prototype-method.js ) - profiles a single method call
43+ * [ profile-prototype-method.js] ( profile-prototype-method.js ) - profiles a single method call
4444that is on a prototype object, not on an instance.
4545* [ profile-separate-calls.js] ( profile-separate-calls.js ) can profile actions where separate
4646method calls start and stop the operation.
@@ -54,9 +54,9 @@ take up in a collection of objects, read [Measuring Space Allocation][measure].
5454
5555### Angular performance
5656
57- * [ ng-count-watchers.js] ( ng-count-watchers.js ) - counts total watchers in the page.
57+ * [ ng-count-watchers.js] ( ng-count-watchers.js ) - counts total watchers in the page.
5858More watchers - slower digest cycle.
59- * [ ng-idle-apply-timing.js] ( ng-idle-apply-timing.js ) - measures how long a digest cycle takes without
59+ * [ ng-idle-apply-timing.js] ( ng-idle-apply-timing.js ) - measures how long a digest cycle takes without
6060any data changes. This measures purely how long all watched expressions take to compute and compare
6161to previous values (dirty checking).
6262* [ ng-profile-scope-method.js] ( ng-profile-scope-method.js ) - installs profile calls around a given
@@ -87,18 +87,18 @@ All snippets, including mine are distributed under MIT license.
8787## Updating local code snippets
8888
8989You can update local code snippets by downloading new versions from this github repository.
90- Create a code snippets and copy source from [ update-code-snippets.js] ( update-code-snippets.js ) .
90+ Create a new code snippet and copy the source from [ update-code-snippets.js] ( update-code-snippets.js ) .
9191
9292You will run this code snippet in an unusual way. First, open any web page, even an empty tab.
93- Open the DevTools in ** undocked** mode (Command+Option+I on Mac). Then open the DevTools ** again** ,
93+ Open the DevTools in ** undocked** mode (Command+Option+I on Mac). Then open the DevTools ** again** ,
9494* while focused* on the first DevTools. This will open the second DevTools instance with the source for the
9595first DevTools panels. If you inspect the ` localStorage ` variable in the second DevTools window, you will
9696find lots of interesting stuff, including all the code snippets in the ` localStorage.scriptSnippets ` property.
9797
9898Whenever you want to update the your local code snippets in the Chrome DevTools, execute the ` update-code-snippets.js `
99- snippet in the second DevTools instance. The update script looks at the your current code snippets and
100- tries to download a file with same name from the code snippets github repository (via [ RawGit] [ RawGit ] ).
101- If the remote file has been downloaded successfully, it will replace the snippet.
99+ snippet in the second DevTools instance. The update script looks at the your current code snippets and
100+ tries to download a file with same name from the code snippets github repository (via [ RawGit] [ RawGit ] ).
101+ If the remote file has been downloaded successfully, it will replace the snippet.
102102After all snippets are checked, reopen the DevTools to load the updated source code.
103103
104104![ update code snippets] ( images/update-code-snippets.png )
@@ -109,7 +109,7 @@ want to override a code snippet - just rename it, for example, remove the `.js`
109109
110110## Remote download a single script
111111
112- You can download and run a single snippet by using the following boilerplate
112+ You can download and run a single snippet by using the following boilerplate
113113(scripts are via downloaded via [ RawGit] [ RawGit ] )
114114
115115``` js
0 commit comments