Adding Analytics logging for JSRefactor, Live Preview, Quick Edit and more features - #14253
Conversation
| WebSocketTransport = require("LiveDevelopment/transports/WebSocketTransport"), | ||
| PreferencesManager = require("preferences/PreferencesManager"); | ||
| PreferencesManager = require("preferences/PreferencesManager"), | ||
| HealthLogger = brackets.getModule("utils/HealthLogger"); |
| "usage", | ||
| "livePreview", | ||
| "open", | ||
| "" |
There was a problem hiding this comment.
This is an optional param no need to send empty string.
| /** | ||
| * Send analytics data for Quick Doc "readMore" action | ||
| * | ||
| * @return {type} [[Description]] |
There was a problem hiding this comment.
fill type and Description field in doc comment.
| } | ||
| if (eventName) { | ||
| // Send analytics data for refactoring | ||
| HealthLogger.sendAnalyticsData( |
There was a problem hiding this comment.
We are not even checking whether we are in js context or not? These commands are available in all type of files. Do we just want capture click on the menu or successful usage of this feature?
There was a problem hiding this comment.
Added the check for JS context.
| } | ||
|
|
||
| //Send analytics data for Quick Edit open | ||
| HealthLogger.sendAnalyticsData( |
There was a problem hiding this comment.
Again do we are just capturing quick edit performed. Are we interested in errors which we get in this operation?
There was a problem hiding this comment.
we just capture logging when quick edit is performed.
| // Send analytics data for Quick Doc open | ||
| HealthLogger.sendAnalyticsData( | ||
| "cssQuickDoc", | ||
| "usage", |
There was a problem hiding this comment.
2nd param is event category? usage might not be the correct word. feature name should be there something like quickedit, multicursor, refactor etc
There was a problem hiding this comment.
@SnchitGrover would be able to clarify this.
|
Just one more question @sobisht |
|
@navch Since unit tests will call the entry functions. Logging will be sent for the unit tests also. This item will be taken care in different PR. |
This PR is related to adding analytics log for following features in brackets:
QuickEdit: open
QuickDoc:
Live Preview: Open
Project Settings: Edit in url
MultiCursor: Use
ping @swmitra @navch