Update Analytics to use Angularitics
This also supports the new Matomo setup.
This commit is contained in:
@@ -1,17 +1,16 @@
|
||||
import {AfterContentInit, Component, OnInit} from '@angular/core';
|
||||
import {Component, OnInit} from '@angular/core';
|
||||
import {ProjectService} from './project.service';
|
||||
import {ProjectItem} from './project-item';
|
||||
import {AnalyticsService} from '../analytics.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-projects',
|
||||
templateUrl: './projects.component.html',
|
||||
styleUrls: ['./projects.component.css'],
|
||||
})
|
||||
export class ProjectsComponent implements OnInit, AfterContentInit {
|
||||
export class ProjectsComponent implements OnInit {
|
||||
projects: Array<ProjectItem>;
|
||||
|
||||
constructor(private projectService: ProjectService, private analytics: AnalyticsService) {
|
||||
constructor(private projectService: ProjectService) {
|
||||
}
|
||||
|
||||
ngOnInit(): void {
|
||||
@@ -22,8 +21,4 @@ export class ProjectsComponent implements OnInit, AfterContentInit {
|
||||
this.projectService.getProjects().then(projects => this.projects = projects);
|
||||
}
|
||||
|
||||
ngAfterContentInit(): void {
|
||||
this.analytics.trackPageHit('Projects');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user