@microsoft/applicationinsights-analytics-js 3.0.0-beta.2303-11 → 3.0.0-beta.2304-07

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/browser/es5/applicationinsights-analytics-js.cjs.js +5452 -0
  2. package/browser/es5/applicationinsights-analytics-js.cjs.js.map +1 -0
  3. package/browser/es5/applicationinsights-analytics-js.cjs.min.js +6 -0
  4. package/browser/es5/applicationinsights-analytics-js.cjs.min.js.map +1 -0
  5. package/browser/es5/applicationinsights-analytics-js.gbl.js +5456 -0
  6. package/browser/es5/applicationinsights-analytics-js.gbl.js.map +1 -0
  7. package/browser/es5/applicationinsights-analytics-js.gbl.min.js +6 -0
  8. package/browser/es5/applicationinsights-analytics-js.gbl.min.js.map +1 -0
  9. package/browser/es5/applicationinsights-analytics-js.integrity.json +66 -0
  10. package/browser/{applicationinsights-analytics-js.js → es5/applicationinsights-analytics-js.js} +898 -867
  11. package/browser/es5/applicationinsights-analytics-js.js.map +1 -0
  12. package/browser/es5/applicationinsights-analytics-js.min.js +6 -0
  13. package/browser/es5/applicationinsights-analytics-js.min.js.map +1 -0
  14. package/dist/{applicationinsights-analytics-js.js → es5/applicationinsights-analytics-js.js} +898 -867
  15. package/dist/es5/applicationinsights-analytics-js.js.map +1 -0
  16. package/dist/es5/applicationinsights-analytics-js.min.js +6 -0
  17. package/dist/es5/applicationinsights-analytics-js.min.js.map +1 -0
  18. package/{dist-esm → dist-es5}/JavaScriptSDK/AnalyticsPlugin.js +2 -2
  19. package/{dist-esm → dist-es5}/JavaScriptSDK/AnalyticsPlugin.js.map +1 -1
  20. package/{dist-esm → dist-es5}/JavaScriptSDK/Telemetry/PageViewManager.js +1 -1
  21. package/{dist-esm → dist-es5}/JavaScriptSDK/Telemetry/PageViewPerformanceManager.js +1 -1
  22. package/{dist-esm → dist-es5}/JavaScriptSDK/Telemetry/PageVisitTimeManager.js +1 -1
  23. package/{dist-esm → dist-es5}/JavaScriptSDK/Timing.js +1 -1
  24. package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITelemetryConfig.js +1 -1
  25. package/{dist-esm → dist-es5}/__DynamicConstants.js +1 -1
  26. package/{dist-esm → dist-es5}/applicationinsights-analytics-js.js +1 -1
  27. package/package.json +19 -18
  28. package/tsconfig.json +5 -4
  29. package/types/applicationinsights-analytics-js.d.ts +181 -2
  30. package/{dist/applicationinsights-analytics-js.d.ts → types/applicationinsights-analytics-js.namespaced.d.ts} +1 -1
  31. package/browser/applicationinsights-analytics-js.integrity.json +0 -26
  32. package/browser/applicationinsights-analytics-js.js.map +0 -1
  33. package/browser/applicationinsights-analytics-js.min.js +0 -6
  34. package/browser/applicationinsights-analytics-js.min.js.map +0 -1
  35. package/dist/applicationinsights-analytics-js.api.json +0 -1845
  36. package/dist/applicationinsights-analytics-js.api.md +0 -100
  37. package/dist/applicationinsights-analytics-js.js.map +0 -1
  38. package/dist/applicationinsights-analytics-js.min.js +0 -6
  39. package/dist/applicationinsights-analytics-js.min.js.map +0 -1
  40. package/dist/applicationinsights-analytics-js.rollup.d.ts +0 -182
  41. package/src/JavaScriptSDK/AnalyticsPlugin.ts +0 -1064
  42. package/src/JavaScriptSDK/Telemetry/PageViewManager.ts +0 -249
  43. package/src/JavaScriptSDK/Telemetry/PageViewPerformanceManager.ts +0 -221
  44. package/src/JavaScriptSDK/Telemetry/PageVisitTimeManager.ts +0 -128
  45. package/src/JavaScriptSDK/Timing.ts +0 -46
  46. package/src/JavaScriptSDK.Interfaces/ITelemetryConfig.ts +0 -13
  47. package/src/__DynamicConstants.ts +0 -56
  48. package/src/applicationinsights-analytics-js.ts +0 -5
  49. package/types/JavaScriptSDK/AnalyticsPlugin.d.ts +0 -140
  50. package/types/JavaScriptSDK/Telemetry/PageViewManager.d.ts +0 -30
  51. package/types/JavaScriptSDK/Telemetry/PageViewPerformanceManager.d.ts +0 -23
  52. package/types/JavaScriptSDK/Telemetry/PageVisitTimeManager.d.ts +0 -25
  53. package/types/JavaScriptSDK/Timing.d.ts +0 -18
  54. package/types/JavaScriptSDK.Interfaces/ITelemetryConfig.d.ts +0 -10
  55. package/types/__DynamicConstants.d.ts +0 -44
  56. package/types/tsdoc-metadata.json +0 -11
  57. /package/{dist-esm → dist-es5}/JavaScriptSDK/Telemetry/PageViewManager.js.map +0 -0
  58. /package/{dist-esm → dist-es5}/JavaScriptSDK/Telemetry/PageViewPerformanceManager.js.map +0 -0
  59. /package/{dist-esm → dist-es5}/JavaScriptSDK/Telemetry/PageVisitTimeManager.js.map +0 -0
  60. /package/{dist-esm → dist-es5}/JavaScriptSDK/Timing.js.map +0 -0
  61. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITelemetryConfig.js.map +0 -0
  62. /package/{dist-esm → dist-es5}/__DynamicConstants.js.map +0 -0
  63. /package/{dist-esm → dist-es5}/applicationinsights-analytics-js.js.map +0 -0
@@ -1,2 +1,181 @@
1
- export { AnalyticsPlugin, AnalyticsPlugin as ApplicationInsights } from "./JavaScriptSDK/AnalyticsPlugin";
2
- export { IAppInsightsInternal } from "./JavaScriptSDK/Telemetry/PageViewManager";
1
+ /*
2
+ * Microsoft Application Insights JavaScript SDK - Web Analytics, 3.0.0-beta.2304-07
3
+ * Copyright (c) Microsoft and contributors. All rights reserved.
4
+ *
5
+ * Microsoft Application Insights Team
6
+ * https://github.com/microsoft/ApplicationInsights-JS#readme
7
+ *
8
+ * ---------------------------------------------------------------------------
9
+ * This is a single combined (rollup) declaration file for the package,
10
+ * if you require a namespace wrapped version it is also available.
11
+ * - Namespaced version: types/applicationinsights-analytics-js.namespaced.d.ts
12
+ * ---------------------------------------------------------------------------
13
+ */
14
+
15
+ import { BaseTelemetryPlugin } from '@microsoft/applicationinsights-core-js';
16
+ import { IAppInsights } from '@microsoft/applicationinsights-common';
17
+ import { IAppInsightsCore } from '@microsoft/applicationinsights-core-js';
18
+ import { IAutoExceptionTelemetry } from '@microsoft/applicationinsights-common';
19
+ import { IConfig } from '@microsoft/applicationinsights-common';
20
+ import { IConfiguration } from '@microsoft/applicationinsights-core-js';
21
+ import { ICookieMgr } from '@microsoft/applicationinsights-core-js';
22
+ import { ICustomProperties } from '@microsoft/applicationinsights-core-js';
23
+ import { IEventTelemetry } from '@microsoft/applicationinsights-common';
24
+ import { IExceptionTelemetry } from '@microsoft/applicationinsights-common';
25
+ import { IMetricTelemetry } from '@microsoft/applicationinsights-common';
26
+ import { IPageViewPerformanceTelemetry } from '@microsoft/applicationinsights-common';
27
+ import { IPageViewPerformanceTelemetryInternal } from '@microsoft/applicationinsights-common';
28
+ import { IPageViewTelemetry } from '@microsoft/applicationinsights-common';
29
+ import { IPageViewTelemetryInternal } from '@microsoft/applicationinsights-common';
30
+ import { IPlugin } from '@microsoft/applicationinsights-core-js';
31
+ import { IProcessTelemetryContext } from '@microsoft/applicationinsights-core-js';
32
+ import { ITelemetryInitializerHandler } from '@microsoft/applicationinsights-core-js';
33
+ import { ITelemetryItem } from '@microsoft/applicationinsights-core-js';
34
+ import { ITelemetryPluginChain } from '@microsoft/applicationinsights-core-js';
35
+ import { ITraceTelemetry } from '@microsoft/applicationinsights-common';
36
+
37
+ declare class AnalyticsPlugin extends BaseTelemetryPlugin implements IAppInsights, IAppInsightsInternal {
38
+ static Version: string;
39
+ identifier: string;
40
+ priority: number;
41
+ readonly config: IConfig;
42
+ queue: Array<() => void>;
43
+ autoRoutePVDelay: number;
44
+ constructor();
45
+ /**
46
+ * Get the current cookie manager for this instance
47
+ */
48
+ getCookieMgr(): ICookieMgr;
49
+ processTelemetry(env: ITelemetryItem, itemCtx?: IProcessTelemetryContext): void;
50
+ trackEvent(event: IEventTelemetry, customProperties?: ICustomProperties): void;
51
+ /**
52
+ * Start timing an extended event. Call `stopTrackEvent` to log the event when it ends.
53
+ * @param name A string that identifies this event uniquely within the document.
54
+ */
55
+ startTrackEvent(name: string): void;
56
+ /**
57
+ * Log an extended event that you started timing with `startTrackEvent`.
58
+ * @param name The string you used to identify this event in `startTrackEvent`.
59
+ * @param properties map[string, string] - additional data used to filter events and metrics in the portal. Defaults to empty.
60
+ * @param measurements map[string, number] - metrics associated with this event, displayed in Metrics Explorer on the portal. Defaults to empty.
61
+ */
62
+ stopTrackEvent(name: string, properties?: {
63
+ [key: string]: string;
64
+ }, measurements?: {
65
+ [key: string]: number;
66
+ }): void;
67
+ /**
68
+ * @description Log a diagnostic message
69
+ * @param trace
70
+ * @param ICustomProperties.
71
+ * @memberof ApplicationInsights
72
+ */
73
+ trackTrace(trace: ITraceTelemetry, customProperties?: ICustomProperties): void;
74
+ /**
75
+ * @description Log a numeric value that is not associated with a specific event. Typically
76
+ * used to send regular reports of performance indicators. To send single measurement, just
77
+ * use the name and average fields of {@link IMetricTelemetry}. If you take measurements
78
+ * frequently, you can reduce the telemetry bandwidth by aggregating multiple measurements
79
+ * and sending the resulting average at intervals
80
+ * @param metric - input object argument. Only name and average are mandatory.
81
+ * @param } customProperties additional data used to filter metrics in the
82
+ * portal. Defaults to empty.
83
+ * @memberof ApplicationInsights
84
+ */
85
+ trackMetric(metric: IMetricTelemetry, customProperties?: ICustomProperties): void;
86
+ /**
87
+ * Logs that a page or other item was viewed.
88
+ * @param IPageViewTelemetry - The string you used as the name in startTrackPage. Defaults to the document title.
89
+ * @param customProperties - Additional data used to filter events and metrics. Defaults to empty.
90
+ * If a user wants to provide duration for pageLoad, it'll have to be in pageView.properties.duration
91
+ */
92
+ trackPageView(pageView?: IPageViewTelemetry, customProperties?: ICustomProperties): void;
93
+ /**
94
+ * Create a page view telemetry item and send it to the SDK pipeline through the core.track API
95
+ * @param pageView - Page view item to be sent
96
+ * @param properties - Custom properties (Part C) that a user can add to the telemetry item
97
+ * @param systemProperties - System level properties (Part A) that a user can add to the telemetry item
98
+ */
99
+ sendPageViewInternal(pageView: IPageViewTelemetryInternal, properties?: {
100
+ [key: string]: any;
101
+ }, systemProperties?: {
102
+ [key: string]: any;
103
+ }): void;
104
+ /**
105
+ * @ignore INTERNAL ONLY
106
+ * @param pageViewPerformance
107
+ * @param properties
108
+ */
109
+ sendPageViewPerformanceInternal(pageViewPerformance: IPageViewPerformanceTelemetryInternal, properties?: {
110
+ [key: string]: any;
111
+ }, systemProperties?: {
112
+ [key: string]: any;
113
+ }): void;
114
+ /**
115
+ * Send browser performance metrics.
116
+ * @param pageViewPerformance
117
+ * @param customProperties
118
+ */
119
+ trackPageViewPerformance(pageViewPerformance: IPageViewPerformanceTelemetry, customProperties?: ICustomProperties): void;
120
+ /**
121
+ * Starts the timer for tracking a page load time. Use this instead of `trackPageView` if you want to control when the page view timer starts and stops,
122
+ * but don't want to calculate the duration yourself. This method doesn't send any telemetry. Call `stopTrackPage` to log the end of the page view
123
+ * and send the event.
124
+ * @param name - A string that idenfities this item, unique within this HTML document. Defaults to the document title.
125
+ */
126
+ startTrackPage(name?: string): void;
127
+ /**
128
+ * Stops the timer that was started by calling `startTrackPage` and sends the pageview load time telemetry with the specified properties and measurements.
129
+ * The duration of the page view will be the time between calling `startTrackPage` and `stopTrackPage`.
130
+ * @param name The string you used as the name in startTrackPage. Defaults to the document title.
131
+ * @param url String - a relative or absolute URL that identifies the page or other item. Defaults to the window location.
132
+ * @param properties map[string, string] - additional data used to filter pages and metrics in the portal. Defaults to empty.
133
+ * @param measurements map[string, number] - metrics associated with this page, displayed in Metrics Explorer on the portal. Defaults to empty.
134
+ */
135
+ stopTrackPage(name?: string, url?: string, properties?: {
136
+ [key: string]: string;
137
+ }, measurement?: {
138
+ [key: string]: number;
139
+ }): void;
140
+ /**
141
+ * @ignore INTERNAL ONLY
142
+ * @param exception
143
+ * @param properties
144
+ * @param systemProperties
145
+ */
146
+ sendExceptionInternal(exception: IExceptionTelemetry, customProperties?: {
147
+ [key: string]: any;
148
+ }, systemProperties?: {
149
+ [key: string]: any;
150
+ }): void;
151
+ /**
152
+ * Log an exception you have caught.
153
+ *
154
+ * @param exception - Object which contains exception to be sent
155
+ * @param } customProperties Additional data used to filter pages and metrics in the portal. Defaults to empty.
156
+ *
157
+ * Any property of type double will be considered a measurement, and will be treated by Application Insights as a metric.
158
+ * @memberof ApplicationInsights
159
+ */
160
+ trackException(exception: IExceptionTelemetry, customProperties?: ICustomProperties): void;
161
+ /**
162
+ * @description Custom error handler for Application Insights Analytics
163
+ * @param exception
164
+ * @memberof ApplicationInsights
165
+ */
166
+ _onerror(exception: IAutoExceptionTelemetry): void;
167
+ addTelemetryInitializer(telemetryInitializer: (item: ITelemetryItem) => boolean | void): ITelemetryInitializerHandler;
168
+ initialize(config: IConfiguration & IConfig, core: IAppInsightsCore, extensions: IPlugin[], pluginChain?: ITelemetryPluginChain): void;
169
+ }
170
+ export { AnalyticsPlugin }
171
+ export { AnalyticsPlugin as ApplicationInsights }
172
+
173
+ /**
174
+ * Internal interface to pass appInsights object to subcomponents without coupling
175
+ */
176
+ export declare interface IAppInsightsInternal {
177
+ sendPageViewInternal(pageViewItem: IPageViewTelemetryInternal, properties?: Object, systemProperties?: Object): void;
178
+ sendPageViewPerformanceInternal(pageViewPerformance: IPageViewPerformanceTelemetryInternal, properties?: Object, systemProperties?: Object): void;
179
+ }
180
+
181
+ export { }
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Microsoft Application Insights JavaScript SDK - Web Analytics, 3.0.0-beta.2303-11
2
+ * Microsoft Application Insights JavaScript SDK - Web Analytics, 3.0.0-beta.2304-07
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  *
5
5
  * Microsoft Application Insights Team
@@ -1,26 +0,0 @@
1
- {
2
- "name": "applicationinsights-analytics-js",
3
- "version": "3.0.0-beta.2303-11",
4
- "ext": {
5
- "@js": {
6
- "file": "applicationinsights-analytics-js.js",
7
- "type": "text/javascript; charset=utf-8",
8
- "integrity": "sha256-I6CJDanZBUs9LioCn5p3XWK0bGGb5ZxuIStHDggoa7Y= sha384-4cGThEhFDvujKaRoUiLVdnp8MHyzK9orupxdZH3uVBq6jYPiMv/ZOfBlxQchDA7i sha512-TOOk/queJOKOpdl7BeZTNMUgQcTcFcraZb8YAdvz2SYbFbx0F4a2ta/GNDutw+l1GydMCbHYWVhkWQJx0qDsfw==",
9
- "hashes": {
10
- "sha256": "I6CJDanZBUs9LioCn5p3XWK0bGGb5ZxuIStHDggoa7Y=",
11
- "sha384": "4cGThEhFDvujKaRoUiLVdnp8MHyzK9orupxdZH3uVBq6jYPiMv/ZOfBlxQchDA7i",
12
- "sha512": "TOOk/queJOKOpdl7BeZTNMUgQcTcFcraZb8YAdvz2SYbFbx0F4a2ta/GNDutw+l1GydMCbHYWVhkWQJx0qDsfw=="
13
- }
14
- },
15
- "@min.js": {
16
- "file": "applicationinsights-analytics-js.min.js",
17
- "type": "text/javascript; charset=utf-8",
18
- "integrity": "sha256-PaxZ4RAagp9SlLOt8AqIyqqCtEx2zgT/gExuLAFdzTo= sha384-1ISWHFnOcrw7dwFI/im+d13vnyP3oH36yZrmUb3elmmZNdxGFD7y04wgE5/pUI6b sha512-6BL6+28rmeVW7OGwDmWYmR5tPeUF2Fl4h6Yq2EXKIHVB56lXTkkVJYaxU5BrpKlEahodtxuO7eq2vNLtcvOuvg==",
19
- "hashes": {
20
- "sha256": "PaxZ4RAagp9SlLOt8AqIyqqCtEx2zgT/gExuLAFdzTo=",
21
- "sha384": "1ISWHFnOcrw7dwFI/im+d13vnyP3oH36yZrmUb3elmmZNdxGFD7y04wgE5/pUI6b",
22
- "sha512": "6BL6+28rmeVW7OGwDmWYmR5tPeUF2Fl4h6Yq2EXKIHVB56lXTkkVJYaxU5BrpKlEahodtxuO7eq2vNLtcvOuvg=="
23
- }
24
- }
25
- }
26
- }