@microsoft/applicationinsights-angularplugin-js 15.4.2-nightly.2608-10 → 15.4.2

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.
package/README.md CHANGED
@@ -59,6 +59,21 @@ export class AppComponent {
59
59
  }
60
60
  ```
61
61
 
62
+ ### Page view titles
63
+
64
+ For automatically tracked route changes, the page view name is read from `document.title`. Angular may update the title after the plugin handles the `NavigationEnd` event, especially when the application uses `TitleStrategy` or a title resolver. In that case, the page view can contain the new URL but the previous page title.
65
+
66
+ To guarantee the page view name, track the page view after the application updates the title and pass the `name` explicitly:
67
+
68
+ ```js
69
+ appInsights.trackPageView({
70
+ name: document.title,
71
+ uri: router.url
72
+ });
73
+ ```
74
+
75
+ See the [sample application](../../sample/applicationinsights-angularplugin-sample/src/app/app.component.ts) for an example of subscribing to router events and calling `trackPageView`. When tracking route changes manually, do not pass `router` in the Angular plugin configuration; otherwise both the plugin and the application will report the same navigation.
76
+
62
77
  To track uncaught exceptions, setup ApplicationinsightsAngularpluginErrorService in `app.module.ts`:
63
78
 
64
79
  > Note: When using the ErrorService there is an implicit dependency on the ```@microsoft/applicationinsights-analytics-js``` extension which is also include in the that your MUST include the ```@microsoft/applicationinsights-web``` Sku, so for uncaught exceptions to be tracked your project MUST be initialized to include the analytics package otherwise unhandled errors caught by the error service will not be sent
@@ -45,10 +45,10 @@ class ApplicationinsightsAngularpluginErrorService {
45
45
  });
46
46
  }
47
47
  }
48
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: ApplicationinsightsAngularpluginErrorService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
49
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: ApplicationinsightsAngularpluginErrorService, providedIn: "root" });
48
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: ApplicationinsightsAngularpluginErrorService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
49
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: ApplicationinsightsAngularpluginErrorService, providedIn: "root" });
50
50
  }
51
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: ApplicationinsightsAngularpluginErrorService, decorators: [{
51
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: ApplicationinsightsAngularpluginErrorService, decorators: [{
52
52
  type: Injectable,
53
53
  args: [{
54
54
  providedIn: "root"
@@ -204,22 +204,22 @@ class AngularPlugin extends BaseTelemetryPlugin {
204
204
  trackPageView(pageView) {
205
205
  // @DynamicProtoStub -- DO NOT add any code as this will be removed during packaging
206
206
  }
207
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: AngularPlugin, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
208
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.21", type: AngularPlugin, isStandalone: false, selector: "lib-applicationinsights-angularplugin-js", usesInheritance: true, ngImport: i0, template: "", isInline: true });
207
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: AngularPlugin, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
208
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.19", type: AngularPlugin, isStandalone: false, selector: "lib-applicationinsights-angularplugin-js", usesInheritance: true, ngImport: i0, template: "", isInline: true });
209
209
  }
210
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: AngularPlugin, decorators: [{
210
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: AngularPlugin, decorators: [{
211
211
  type: Component,
212
212
  args: [{ selector: "lib-applicationinsights-angularplugin-js", template: "", standalone: false }]
213
213
  }], ctorParameters: () => [{ type: i0.Injector }] });
214
214
 
215
215
  class ApplicationinsightsAngularpluginJsModule {
216
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: ApplicationinsightsAngularpluginJsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
217
- static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.2.21", ngImport: i0, type: ApplicationinsightsAngularpluginJsModule, declarations: [AngularPlugin], exports: [AngularPlugin] });
218
- static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: ApplicationinsightsAngularpluginJsModule, providers: [
216
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: ApplicationinsightsAngularpluginJsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
217
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.2.19", ngImport: i0, type: ApplicationinsightsAngularpluginJsModule, declarations: [AngularPlugin], exports: [AngularPlugin] });
218
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: ApplicationinsightsAngularpluginJsModule, providers: [
219
219
  ApplicationinsightsAngularpluginErrorService
220
220
  ] });
221
221
  }
222
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: ApplicationinsightsAngularpluginJsModule, decorators: [{
222
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: ApplicationinsightsAngularpluginJsModule, decorators: [{
223
223
  type: NgModule,
224
224
  args: [{
225
225
  declarations: [AngularPlugin],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@microsoft/applicationinsights-angularplugin-js",
3
- "version": "15.4.2-nightly.2608-10",
3
+ "version": "15.4.2",
4
4
  "description": "Microsoft Application Insights Angular plugin",
5
5
  "author": "Microsoft Application Insights Team",
6
6
  "license": "MIT",
@@ -14,18 +14,15 @@
14
14
  "homepage": "https://github.com/microsoft/applicationinsights-angularplugin-js#readme",
15
15
  "dependencies": {
16
16
  "@microsoft/applicationinsights-shims": "^3.0.1",
17
- "@microsoft/applicationinsights-core-js": "nightly3",
18
- "@microsoft/applicationinsights-properties-js": "nightly3",
17
+ "@microsoft/applicationinsights-core-js": "^3.4.4",
18
+ "@microsoft/applicationinsights-properties-js": "^3.4.4",
19
19
  "tslib": "^2.0.0"
20
20
  },
21
21
  "peerDependencies": {
22
- "@microsoft/applicationinsights-analytics-js": "nightly3",
22
+ "@microsoft/applicationinsights-analytics-js": "^3.4.4",
23
23
  "@angular/common": ">= 15.0.0",
24
24
  "@angular/core": ">= 15.0.0"
25
25
  },
26
- "publishConfig": {
27
- "tag": "nightly"
28
- },
29
26
  "module": "fesm2022/microsoft-applicationinsights-angularplugin-js.mjs",
30
27
  "typings": "types/microsoft-applicationinsights-angularplugin-js.d.ts",
31
28
  "exports": {