Skip to content

Commit

Permalink
chore(landing): replace plausible in favor of metricswave
Browse files Browse the repository at this point in the history
  • Loading branch information
dimaslz committed Oct 2, 2024
1 parent 0ff3189 commit 58388c2
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 28 deletions.
17 changes: 3 additions & 14 deletions landing/src/app/app.component.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { CommonModule, isPlatformBrowser } from '@angular/common';
import { Component, Inject, PLATFORM_ID } from '@angular/core';
import { CommonModule } from '@angular/common';
import { Component } from '@angular/core';
import { RouterLink, RouterOutlet } from '@angular/router';
import { NgHeroiconsModule } from '@dimaslz/ng-heroicons';

Expand Down Expand Up @@ -28,18 +28,7 @@ export class AppComponent {
public copied = false;
public color = 'white';

constructor(@Inject(PLATFORM_ID) private platformId: object) {
if (isPlatformBrowser(this.platformId)) {
const node: HTMLScriptElement = document.createElement('script');
node.src = 'https://plausible.io/js/plausible.js';
node.type = 'text/javascript';
node.async = true;
node.defer = true;
node.dataset['domain'] = 'ng-heroicons.dimaslz.dev';

document.getElementsByTagName('head')[0].appendChild(node);
}
}
constructor() {}

onClickCommandExample($event: MouseEvent): void {
this.copied = true;
Expand Down
17 changes: 3 additions & 14 deletions landing/src/app/pages/home/home.component.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { CommonModule, isPlatformBrowser } from '@angular/common';
import { Component, Inject, PLATFORM_ID } from '@angular/core';
import { CommonModule } from '@angular/common';
import { Component } from '@angular/core';
import { NgHeroiconsModule } from '@dimaslz/ng-heroicons';

import { DarkModeModule } from '@/components/darkmode-toggle/darkmode-toggle.module';
Expand All @@ -25,18 +25,7 @@ export class HomePageComponent {
public copied = false;
public color = 'white';

constructor(@Inject(PLATFORM_ID) private platformId: object) {
if (isPlatformBrowser(this.platformId)) {
const node: HTMLScriptElement = document.createElement('script');
node.src = 'https://plausible.io/js/plausible.js';
node.type = 'text/javascript';
node.async = true;
node.defer = true;
node.dataset['domain'] = 'ng-heroicons.dimaslz.dev';

document.getElementsByTagName('head')[0].appendChild(node);
}
}
constructor() {}

onClickCommandExample($event: MouseEvent): void {
this.copied = true;
Expand Down
1 change: 1 addition & 0 deletions landing/src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
<html lang="en">
<head>
<meta charset="utf-8">
<script defer event-uuid="a7c9759e-1a36-453a-aa44-014b098143e7" src="https://tracker.metricswave.com/js/visits.js"></script>
<title>ng-heroicons _ heroicons.com Angular components - by dimaslz</title>
<meta name="robots" content="index, follow" />
<meta name="description" content="NgHeroicons just it is an Angular components to use Heroicons.com icons in your projects. I hope that could be useful.">
Expand Down

0 comments on commit 58388c2

Please sign in to comment.