trackPage

Prev Next

The trackPage method sends the collected data to our track servers. After sending, the pixel automatically deletes all data from the cache and cannot access it anymore.

WebtrekkSmartPixelAngular

Value

Notes

Data Type

Default Value

Required

keepData

After sending the tracking data, the Smart Pixel automatically removes all defined data. If you want to keep the data, set true as the first argument, then you can delete the data manually.

Boolean

false

-

import { Component } from '@angular/core';
import { WebtrekkSmartPixelAngular } from '@webtrekk-smart-pixel/angular';

@Component({
    template: `<div>[ ... ]</div>`
})
export class ExampleComponent {
    constructor(private pixel: WebtrekkSmartPixelAngular) {
        this.pixel.trackPage(false);
    }
}