Javascript Profiling: Difference between revisions

Jump to navigation Jump to search
m
(remove a TODO that's irrelevant)
Line 7: Line 7:
Here's a rough idea of what the API would be like from the javascript side of things:
Here's a rough idea of what the API would be like from the javascript side of things:


* <tt>proflier.start() : unit &rarr; unit</tt> - This beings profiling the current page, setting up all necessary internal information. Throws an error if profiling has already been started.
* <tt>profiler.start() : unit &rarr; unit</tt> - This beings profiling the current page, setting up all necessary internal information. Throws an error if profiling has already been started.
* <tt>profiler.running() : unit &rarr; bool</tt> - Tests whether the profiler is currently running, returning <tt>true</tt> if it is or <tt>false</tt> otherwise.
* <tt>profiler.running() : unit &rarr; bool</tt> - Tests whether the profiler is currently running, returning <tt>true</tt> if it is or <tt>false</tt> otherwise.
* <tt>proflier.event(a) : object &rarr; unit</tt> - Fires a custom profiling event from javascript, the provided object is used to identify the event. Throws an error if profiling is not currently running.
* <tt>proflier.event(a) : object &rarr; unit</tt> - Fires a custom profiling event from javascript, the provided object is used to identify the event. Throws an error if profiling is not currently running.
Confirmed users
497

edits

Navigation menu